@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | protected static function getRegisteredType(array $columnDefinition) |
| 42 | 42 | { |
| 43 | 43 | foreach (self::$registeredTypes as $class) { |
| 44 | - if (call_user_func([ $class, 'fits' ], $columnDefinition)) { |
|
| 44 | + if (call_user_func([$class, 'fits'], $columnDefinition)) { |
|
| 45 | 45 | return $class; |
| 46 | 46 | } |
| 47 | 47 | } |
@@ -114,8 +114,7 @@ discard block |
||
| 114 | 114 | public function __get($name) |
| 115 | 115 | { |
| 116 | 116 | $method = [$this, 'get' . ucfirst($name)]; |
| 117 | - return is_callable($method) ? call_user_func($method) : |
|
| 118 | - (isset($this->columnDefinition[$name]) ? $this->columnDefinition[$name] : null); |
|
| 117 | + return is_callable($method) ? call_user_func($method) : (isset($this->columnDefinition[$name]) ? $this->columnDefinition[$name] : null); |
|
| 119 | 118 | } |
| 120 | 119 | |
| 121 | 120 | /** |
@@ -183,11 +182,11 @@ discard block |
||
| 183 | 182 | $class = $this->columnDefinition['type']; |
| 184 | 183 | } |
| 185 | 184 | |
| 186 | - if ($class === null || !is_callable([ $class, 'factory' ])) { |
|
| 185 | + if ($class === null || !is_callable([$class, 'factory'])) { |
|
| 187 | 186 | $class = Type\Text::class; |
| 188 | 187 | } |
| 189 | 188 | |
| 190 | - $this->type = call_user_func([ $class, 'factory' ], $this->dbal, $this->columnDefinition); |
|
| 189 | + $this->type = call_user_func([$class, 'factory'], $this->dbal, $this->columnDefinition); |
|
| 191 | 190 | } |
| 192 | 191 | |
| 193 | 192 | return $this->type; |