@@ -17,7 +17,7 @@ |
||
| 17 | 17 | */ |
| 18 | 18 | private static $twig; |
| 19 | 19 | |
| 20 | - public static function &getInstance () |
|
| 20 | + public static function &getInstance() |
|
| 21 | 21 | { |
| 22 | 22 | return self::$twig; |
| 23 | 23 | } |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | /** |
| 51 | 51 | * {@inheritdoc} |
| 52 | 52 | */ |
| 53 | - public function refreshItem($filePath) |
|
| 53 | + public function refreshItem ($filePath) |
|
| 54 | 54 | { |
| 55 | 55 | $relativeFilePath = str_replace($this->themeFolderRelative . '/', '', $filePath); |
| 56 | 56 | |
@@ -60,7 +60,7 @@ discard block |
||
| 60 | 60 | /** |
| 61 | 61 | * {@inheritdoc} |
| 62 | 62 | */ |
| 63 | - public function isHandled($filePath) |
|
| 63 | + public function isHandled ($filePath) |
|
| 64 | 64 | { |
| 65 | 65 | $isThemeAsset = (substr($filePath, 0, strlen($this->themeFolderRelative)) === $this->themeFolderRelative); |
| 66 | 66 | |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | /** |
| 71 | 71 | * {@inheritdoc} |
| 72 | 72 | */ |
| 73 | - public function createNewItem($filePath) |
|
| 73 | + public function createNewItem ($filePath) |
|
| 74 | 74 | { |
| 75 | 75 | $relativeFilePath = str_replace($this->themeFolderRelative . '/', '', $filePath); |
| 76 | 76 | |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | |
| 25 | 25 | if (!$this->fs->exists($this->themeFolder)) |
| 26 | 26 | { |
| 27 | - throw new FileNotFoundException("The '${themeName}' theme folder could not be found.'"); |
|
| 27 | + throw new FileNotFoundException("The '${themename}' theme folder could not be found.'"); |
|
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | if ($this->fs->exists($this->themeFile)) |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | * |
| 31 | 31 | * @return ContentItem[][] |
| 32 | 32 | */ |
| 33 | - public function &getCollections () |
|
| 33 | + public function &getCollections() |
|
| 34 | 34 | { |
| 35 | 35 | return $this->trackedItems; |
| 36 | 36 | } |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | * |
| 45 | 45 | * @return ContentItem |
| 46 | 46 | */ |
| 47 | - public function &getContentItem ($filePath) |
|
| 47 | + public function &getContentItem($filePath) |
|
| 48 | 48 | { |
| 49 | 49 | if (!isset($this->trackedItemsFlattened[$filePath])) |
| 50 | 50 | { |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | /** |
| 120 | 120 | * {@inheritdoc} |
| 121 | 121 | */ |
| 122 | - public function createNewItem($filePath) |
|
| 122 | + public function createNewItem ($filePath) |
|
| 123 | 123 | { |
| 124 | 124 | $collection = $this->getTentativeCollectionName($filePath); |
| 125 | 125 | |
@@ -131,7 +131,7 @@ discard block |
||
| 131 | 131 | /** |
| 132 | 132 | * {@inheritdoc} |
| 133 | 133 | */ |
| 134 | - public function refreshItem($filePath) |
|
| 134 | + public function refreshItem ($filePath) |
|
| 135 | 135 | { |
| 136 | 136 | return; |
| 137 | 137 | } |
@@ -139,7 +139,7 @@ discard block |
||
| 139 | 139 | /** |
| 140 | 140 | * {@inheritdoc} |
| 141 | 141 | */ |
| 142 | - protected function handleTrackableItem($filePath, $options = array()) |
|
| 142 | + protected function handleTrackableItem ($filePath, $options = array()) |
|
| 143 | 143 | { |
| 144 | 144 | $collectionName = $options['namespace']; |
| 145 | 145 | |
@@ -64,7 +64,9 @@ discard block |
||
| 64 | 64 | */ |
| 65 | 65 | public function parseDataItems ($folders) |
| 66 | 66 | { |
| 67 | - if ($folders === null) { return; } |
|
| 67 | + if ($folders === null) |
|
| 68 | + { |
|
| 69 | +return; } |
|
| 68 | 70 | |
| 69 | 71 | foreach ($folders as $folder) |
| 70 | 72 | { |
@@ -84,7 +86,9 @@ discard block |
||
| 84 | 86 | */ |
| 85 | 87 | public function parseDataSets ($dataSets) |
| 86 | 88 | { |
| 87 | - if ($dataSets === null) { return; } |
|
| 89 | + if ($dataSets === null) |
|
| 90 | + { |
|
| 91 | +return; } |
|
| 88 | 92 | |
| 89 | 93 | /** |
| 90 | 94 | * The information which each DataSet has from the configuration file |
@@ -28,7 +28,7 @@ |
||
| 28 | 28 | /** |
| 29 | 29 | * {@inheritdoc} |
| 30 | 30 | */ |
| 31 | - public function setLogger(LoggerInterface $logger) |
|
| 31 | + public function setLogger (LoggerInterface $logger) |
|
| 32 | 32 | { |
| 33 | 33 | $this->output = $logger; |
| 34 | 34 | } |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | /** |
| 47 | 47 | * Copy all of the assets |
| 48 | 48 | */ |
| 49 | - public function copyFiles() |
|
| 49 | + public function copyFiles () |
|
| 50 | 50 | { |
| 51 | 51 | $this->scanTrackableItems( |
| 52 | 52 | getcwd(), |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | /** |
| 65 | 65 | * {@inheritdoc} |
| 66 | 66 | */ |
| 67 | - public function isHandled($filePath) |
|
| 67 | + public function isHandled ($filePath) |
|
| 68 | 68 | { |
| 69 | 69 | return $this->fileExplorer->matchesPattern($filePath); |
| 70 | 70 | } |
@@ -72,7 +72,7 @@ discard block |
||
| 72 | 72 | /** |
| 73 | 73 | * {@inheritdoc} |
| 74 | 74 | */ |
| 75 | - public function createNewItem($filePath) |
|
| 75 | + public function createNewItem ($filePath) |
|
| 76 | 76 | { |
| 77 | 77 | return $this->handleTrackableItem($filePath, array( |
| 78 | 78 | 'prefix' => '' |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | /** |
| 83 | 83 | * {@inheritdoc} |
| 84 | 84 | */ |
| 85 | - protected function handleTrackableItem($file, $options = array()) |
|
| 85 | + protected function handleTrackableItem ($file, $options = array()) |
|
| 86 | 86 | { |
| 87 | 87 | if (is_string($file)) |
| 88 | 88 | { |
@@ -90,7 +90,9 @@ |
||
| 90 | 90 | $file = $this->fs->createSplFileInfo($file); |
| 91 | 91 | } |
| 92 | 92 | |
| 93 | - if (!$this->fs->exists($file)) { return; } |
|
| 93 | + if (!$this->fs->exists($file)) |
|
| 94 | + { |
|
| 95 | +return; } |
|
| 94 | 96 | |
| 95 | 97 | $filePath = $file->getRealPath(); |
| 96 | 98 | $pathToStrip = $this->fs->appendPath(getcwd(), $options['prefix']); |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | * |
| 40 | 40 | * @param string $string |
| 41 | 41 | */ |
| 42 | - public function __construct($string) |
|
| 42 | + public function __construct ($string) |
|
| 43 | 43 | { |
| 44 | 44 | $this->evaluated = $string; |
| 45 | 45 | } |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | /** |
| 48 | 48 | * @return string |
| 49 | 49 | */ |
| 50 | - public function __toString() |
|
| 50 | + public function __toString () |
|
| 51 | 51 | { |
| 52 | 52 | return $this->getEvaluated(); |
| 53 | 53 | } |
@@ -171,9 +171,9 @@ |
||
| 171 | 171 | public function removeExtension ($filename) |
| 172 | 172 | { |
| 173 | 173 | return $this->appendPath( |
| 174 | - $this->getFolderPath($filename), |
|
| 175 | - $this->getBaseName($filename) |
|
| 176 | - ); |
|
| 174 | + $this->getFolderPath($filename), |
|
| 175 | + $this->getBaseName($filename) |
|
| 176 | + ); |
|
| 177 | 177 | } |
| 178 | 178 | |
| 179 | 179 | /** |
@@ -62,7 +62,7 @@ |
||
| 62 | 62 | * @throws FileNotFoundException When originFile doesn't exist |
| 63 | 63 | * @throws IOException When copy fails |
| 64 | 64 | */ |
| 65 | - public function copy($originFile, $targetFile, $overwriteNewerFiles = false) |
|
| 65 | + public function copy ($originFile, $targetFile, $overwriteNewerFiles = false) |
|
| 66 | 66 | { |
| 67 | 67 | if ($this->isDir($originFile)) |
| 68 | 68 | { |
@@ -76,7 +76,9 @@ |
||
| 76 | 76 | while (false !== $entry = $dir->read()) |
| 77 | 77 | { |
| 78 | 78 | // Skip pointers |
| 79 | - if ($entry == '.' || $entry == '..') { continue; } |
|
| 79 | + if ($entry == '.' || $entry == '..') |
|
| 80 | + { |
|
| 81 | +continue; } |
|
| 80 | 82 | |
| 81 | 83 | $this->copy("$originFile/$entry", "$targetFile/$entry", true); |
| 82 | 84 | } |
@@ -15,7 +15,7 @@ |
||
| 15 | 15 | /** @var PageView */ |
| 16 | 16 | private $siteMenu; |
| 17 | 17 | |
| 18 | - public function __construct() |
|
| 18 | + public function __construct () |
|
| 19 | 19 | { |
| 20 | 20 | parent::__construct(); |
| 21 | 21 | |