Skip to content

Commit 573ea1b

Browse files
authored
Merge pull request #28 from dreammonkey/feature/skip-columns-default
add default [] for schema-rules.skip_columns to prevent errors when config is not published.
2 parents 8541205 + 1fecfc9 commit 573ea1b

5 files changed

+5
-13
lines changed

src/Exceptions/ColumnDoesNotExistException.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@
44

55
use Exception;
66

7-
class ColumnDoesNotExistException extends Exception
8-
{
9-
}
7+
class ColumnDoesNotExistException extends Exception {}

src/Exceptions/MultipleTablesSuppliedException.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@
44

55
use Exception;
66

7-
class MultipleTablesSuppliedException extends Exception
8-
{
9-
}
7+
class MultipleTablesSuppliedException extends Exception {}

src/Exceptions/TableDoesNotExistException.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@
44

55
use Exception;
66

7-
class TableDoesNotExistException extends Exception
8-
{
9-
}
7+
class TableDoesNotExistException extends Exception {}

src/Exceptions/UnsupportedDbDriverException.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@
44

55
use Exception;
66

7-
class UnsupportedDbDriverException extends Exception
8-
{
9-
}
7+
class UnsupportedDbDriverException extends Exception {}

src/Resolvers/BaseSchemaRulesResolver.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public function generate(): array
2121
{
2222
$tableColumns = $this->getColumnsDefinitionsFromTable();
2323

24-
$skip_columns = config('schema-rules.skip_columns');
24+
$skip_columns = config('schema-rules.skip_columns', []);
2525

2626
$tableRules = [];
2727
foreach ($tableColumns as $column) {

0 commit comments

Comments
 (0)