We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -12,14 +12,14 @@ |
||
12 | 12 | |-------------------------------------------------------------------------- |
13 | 13 | */ |
14 | 14 | |
15 | - public static function getPossibleEnumValues($field_name){ |
|
15 | + public static function getPossibleEnumValues($field_name) { |
|
16 | 16 | $instance = new static; // create an instance of the model to be able to get the table name |
17 | - $type = DB::select( DB::raw('SHOW COLUMNS FROM '.$instance->getTable().' WHERE Field = "'.$field_name.'"') )[0]->Type; |
|
17 | + $type = DB::select(DB::raw('SHOW COLUMNS FROM '.$instance->getTable().' WHERE Field = "'.$field_name.'"'))[0]->Type; |
|
18 | 18 | preg_match('/^enum\((.*)\)$/', $type, $matches); |
19 | 19 | $enum = array(); |
20 | 20 | $exploded = explode(',', $matches[1]); |
21 | - foreach($exploded as $value){ |
|
22 | - $v = trim( $value, "'" ); |
|
21 | + foreach ($exploded as $value) { |
|
22 | + $v = trim($value, "'"); |
|
23 | 23 | $enum[] = $v; |
24 | 24 | } |
25 | 25 | return $enum; |