diff --git a/src/Archiver/BaseArchiver.php b/src/Archiver/BaseArchiver.php index 4aaa726..5bc7fbe 100644 --- a/src/Archiver/BaseArchiver.php +++ b/src/Archiver/BaseArchiver.php @@ -18,9 +18,9 @@ abstract class BaseArchiver extends BaseHandler * * @param string $path The path to the file * - * @throws FileNotFoundException - * * @return bool Success or failure + * + * @throws FileNotFoundException */ protected function putContents($path, string $data): bool { diff --git a/src/Collectors/Schema.php b/src/Collectors/Schema.php index 9af3260..b603cfc 100644 --- a/src/Collectors/Schema.php +++ b/src/Collectors/Schema.php @@ -48,7 +48,7 @@ class Schema extends BaseCollector */ protected $schema; - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- /** * Load a copy of the schema. @@ -73,7 +73,7 @@ public function getTitleDetails(): string return '(' . (is_countable($this->schema->tables) ? count($this->schema->tables) : 0) . ' tables)'; } - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- /** * Returns the data of this collector to be formatted in the toolbar @@ -97,7 +97,7 @@ public function display(): string return $html; } - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- /** * Gets the "badge" value for the button. @@ -107,7 +107,7 @@ public function getBadgeValue(): int return empty($this->schema->tables) ? 0 : count($this->schema->tables); } - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- /** * Display the icon. diff --git a/src/Config/Schemas.php b/src/Config/Schemas.php index 135ace8..53b7ea0 100644 --- a/src/Config/Schemas.php +++ b/src/Config/Schemas.php @@ -16,9 +16,9 @@ class Schemas extends BaseConfig 'read' => true, ]; - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Drafting - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Default handlers used to create a schema (order sensitive) // (Probably shouldn't change this unless you really know what you're doing) @@ -40,9 +40,9 @@ class Schemas extends BaseConfig // Path the directoryHandler should scan for schema files public $schemasDirectory = APPPATH . 'Schemas'; - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Archiving - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Default handlers to archive copies of the schema public $archiveHandlers = [ @@ -52,16 +52,16 @@ class Schemas extends BaseConfig // Default time-to-live for a stored schema (e.g. Cache) in seconds public $ttl = 14400; // 4 hours - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Reading - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Default handler used to return and read a schema public $readHandler = 'Tatter\Schemas\Reader\Handlers\CacheHandler'; - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Publishing - //-------------------------------------------------------------------- + // -------------------------------------------------------------------- // Precaution to prevent accidental wiping of databases or files public $safeMode = true; diff --git a/src/Structures/Mergeable.php b/src/Structures/Mergeable.php index 8e791ce..f7c6c1c 100644 --- a/src/Structures/Mergeable.php +++ b/src/Structures/Mergeable.php @@ -5,9 +5,10 @@ use ArrayIterator; use Countable; use IteratorAggregate; +use stdClass; use Traversable; -class Mergeable implements Countable, IteratorAggregate +class Mergeable extends stdClass implements Countable, IteratorAggregate { /** * Merge two structures together. diff --git a/tests/read/CacheReaderTest.php b/tests/read/CacheReaderTest.php index f90df58..6a7bd47 100644 --- a/tests/read/CacheReaderTest.php +++ b/tests/read/CacheReaderTest.php @@ -1,7 +1,6 @@