@@ -67,7 +67,7 @@ |
||
67 | 67 | $view = $view($uri, $engine); |
68 | 68 | } |
69 | 69 | |
70 | - if (! $view instanceof ViewInterface) { |
|
70 | + if ( ! $view instanceof ViewInterface) { |
|
71 | 71 | throw new FailedToInstantiateViewException( |
72 | 72 | sprintf( |
73 | 73 | _('Could not instantiate view "%s".'), |
@@ -56,7 +56,7 @@ |
||
56 | 56 | */ |
57 | 57 | public function render($uri, array $context = []) |
58 | 58 | { |
59 | - if (! is_readable($uri)) { |
|
59 | + if ( ! is_readable($uri)) { |
|
60 | 60 | throw new FailedToLoadViewException( |
61 | 61 | sprintf( |
62 | 62 | _('The View URI "%1$s" is not accessible or readable.'), |
@@ -85,7 +85,7 @@ |
||
85 | 85 | $engine = $engine(); |
86 | 86 | } |
87 | 87 | |
88 | - if (! $engine instanceof EngineInterface) { |
|
88 | + if ( ! $engine instanceof EngineInterface) { |
|
89 | 89 | throw new FailedToInstantiateEngineException( |
90 | 90 | sprintf( |
91 | 91 | _('Could not instantiate engine "%s".'), |
@@ -226,7 +226,7 @@ |
||
226 | 226 | $type = $type($uri, $engine); |
227 | 227 | } |
228 | 228 | |
229 | - if (! $type instanceof ViewInterface) { |
|
229 | + if ( ! $type instanceof ViewInterface) { |
|
230 | 230 | throw new FailedToInstantiateViewException( |
231 | 231 | sprintf( |
232 | 232 | _('Could not instantiate view "%s".'), |
@@ -89,7 +89,7 @@ |
||
89 | 89 | */ |
90 | 90 | public static function getDefaultConfig() |
91 | 91 | { |
92 | - return ConfigFactory::create(__DIR__ . '/../config/defaults.php') |
|
92 | + return ConfigFactory::create(__DIR__.'/../config/defaults.php') |
|
93 | 93 | ->getSubConfig('BrightNucleus\View'); |
94 | 94 | } |
95 | 95 |
@@ -146,7 +146,7 @@ |
||
146 | 146 | */ |
147 | 147 | protected function initializeNullObject() |
148 | 148 | { |
149 | - if (! is_object($this->nullObject)) { |
|
149 | + if ( ! is_object($this->nullObject)) { |
|
150 | 150 | $this->nullObject = new $this->nullObject(); |
151 | 151 | } |
152 | 152 | } |
@@ -36,7 +36,7 @@ |
||
36 | 36 | */ |
37 | 37 | public function render(array $context = [], $echo = false) |
38 | 38 | { |
39 | - if (! $echo) { |
|
39 | + if ( ! $echo) { |
|
40 | 40 | return ''; |
41 | 41 | } |
42 | 42 | } |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | |
92 | 92 | foreach ($criteria as $entry) { |
93 | 93 | if ($uri = $this->transform($entry, false)) { |
94 | - $uris = array_merge($uris, (array)$uri); |
|
94 | + $uris = array_merge($uris, (array) $uri); |
|
95 | 95 | } |
96 | 96 | } |
97 | 97 | |
@@ -144,9 +144,9 @@ discard block |
||
144 | 144 | { |
145 | 145 | $variants = []; |
146 | 146 | |
147 | - array_map(function ($extension) use ($entry, &$variants) { |
|
148 | - $variants[] = $entry . $extension; |
|
149 | - $variants[] = $this->path . DIRECTORY_SEPARATOR . $entry . $extension; |
|
147 | + array_map(function($extension) use ($entry, &$variants) { |
|
148 | + $variants[] = $entry.$extension; |
|
149 | + $variants[] = $this->path.DIRECTORY_SEPARATOR.$entry.$extension; |
|
150 | 150 | }, $this->extensions); |
151 | 151 | |
152 | 152 | return $variants; |