@@ -32,7 +32,7 @@ |
||
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | $options = []; |
| 35 | - if(isset($minifyOptions[$type])){ |
|
| 35 | + if (isset($minifyOptions[$type])) { |
|
| 36 | 36 | $options = $minifyOptions[$type]; |
| 37 | 37 | } |
| 38 | 38 | return new $minifyClass($content, $options); |
@@ -63,7 +63,7 @@ |
||
| 63 | 63 | ); |
| 64 | 64 | } |
| 65 | 65 | |
| 66 | - if(!in_array($method, ['push', 'unshift'],true)){ |
|
| 66 | + if (!in_array($method, ['push', 'unshift'], true)) { |
|
| 67 | 67 | throw new NotAllowedMethods('Allowed methods only `push` and `unshift`'); |
| 68 | 68 | } |
| 69 | 69 | |
@@ -30,7 +30,7 @@ |
||
| 30 | 30 | string $render = Assets::RENDER_HTML |
| 31 | 31 | ): RenderInterface { |
| 32 | 32 | |
| 33 | - if(!array_key_exists($render, self::RENDERS)){ |
|
| 33 | + if (!array_key_exists($render, self::RENDERS)) { |
|
| 34 | 34 | throw new UnexpectedParameters( |
| 35 | 35 | sprintf('Invalid render group. Allowed only: %s', implode(', ', array_keys(self::RENDERS))) |
| 36 | 36 | ); |
@@ -60,12 +60,12 @@ |
||
| 60 | 60 | |
| 61 | 61 | public function push(AssetsCollection $collection): void |
| 62 | 62 | { |
| 63 | - $this->assets = array_merge_recursive_distinct($this->getAssets(), $collection->getAssets()); |
|
| 63 | + $this->assets = array_merge_recursive_distinct($this->getAssets(), $collection->getAssets()); |
|
| 64 | 64 | } |
| 65 | 65 | |
| 66 | 66 | public function unshift(AssetsCollection $collection): void |
| 67 | 67 | { |
| 68 | - $this->assets = array_merge_recursive_distinct($collection->getAssets(), $this->getAssets()); |
|
| 68 | + $this->assets = array_merge_recursive_distinct($collection->getAssets(), $this->getAssets()); |
|
| 69 | 69 | } |
| 70 | 70 | |
| 71 | 71 | public function getAssets(): array |
@@ -33,7 +33,7 @@ |
||
| 33 | 33 | { |
| 34 | 34 | $result = preg_replace_callback( |
| 35 | 35 | '/(url\([\'"]?)(?!["\'a-z]+:|[\'"]?\/{2})(.+[^\'"])([\'"]?\))/i', |
| 36 | - function (array $m) { |
|
| 36 | + function(array $m) { |
|
| 37 | 37 | /** @var string[] $m */ |
| 38 | 38 | $urlConverter = new UrlConverter(); |
| 39 | 39 | |
@@ -35,7 +35,7 @@ |
||
| 35 | 35 | { |
| 36 | 36 | $result = preg_replace_callback( |
| 37 | 37 | '/(url\([\'"]?)(?!["\'a-z]+:|[\'"]?\/{2})(.+?[^\'"])([\'"]?\))/i', |
| 38 | - function (array $m) { |
|
| 38 | + function(array $m) { |
|
| 39 | 39 | /** @var string[] $m */ |
| 40 | 40 | $realpath = realpath($this->path . parse_url($m[2], PHP_URL_PATH)); |
| 41 | 41 | |