@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | namespace Nexendrie\SiteGenerator; |
5 | 5 | |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | $this->output = realpath($output); |
69 | 69 | } |
70 | 70 | |
71 | - protected function getMeta(string $filename, string &$html): array { |
|
71 | + protected function getMeta(string $filename, string & $html): array { |
|
72 | 72 | $resolver = new OptionsResolver(); |
73 | 73 | $resolver->setDefaults([ |
74 | 74 | "title" => "", |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | } |
102 | 102 | } |
103 | 103 | |
104 | - protected function normalizeTitle(array &$meta, string &$html, string $filename): void { |
|
104 | + protected function normalizeTitle(array &$meta, string & $html, string $filename): void { |
|
105 | 105 | if(strlen($meta["title"]) === 0) { |
106 | 106 | unset($meta["title"]); |
107 | 107 | $html = str_replace(" |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | } |
110 | 110 | } |
111 | 111 | |
112 | - protected function normalizeStyles(array &$meta, string &$html, string $filename): void { |
|
112 | + protected function normalizeStyles(array &$meta, string & $html, string $filename): void { |
|
113 | 113 | $basePath = dirname($filename); |
114 | 114 | $meta["styles"] = array_filter($meta["styles"], function($value) use($basePath) { |
115 | 115 | return file_exists("$basePath/$value"); |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | $meta["styles"] = implode("\n ", $meta["styles"]); |
128 | 128 | } |
129 | 129 | |
130 | - protected function normalizeScripts(array &$meta, string &$html, string $filename): void { |
|
130 | + protected function normalizeScripts(array &$meta, string & $html, string $filename): void { |
|
131 | 131 | $basePath = dirname($filename); |
132 | 132 | $meta["scripts"] = array_filter($meta["scripts"], function($value) use($basePath) { |
133 | 133 | return file_exists("$basePath/$value"); |
@@ -172,7 +172,7 @@ discard block |
||
172 | 172 | $path = str_replace($this->source, "", $asset); |
173 | 173 | $target = "$this->output$path"; |
174 | 174 | FileSystem::copy($asset, $target); |
175 | - echo "Copied $path"; |
|
175 | + echo "copied $path"; |
|
176 | 176 | } |
177 | 177 | } |
178 | 178 | |
@@ -196,7 +196,7 @@ discard block |
||
196 | 196 | $basename = $file->getBasename(".md") . ".html"; |
197 | 197 | $filename = "$this->output$path/$basename"; |
198 | 198 | FileSystem::write($filename, $html); |
199 | - echo "Created $path/$basename\n"; |
|
199 | + echo "created $path/$basename\n"; |
|
200 | 200 | } |
201 | 201 | $this->onAfterGenerate(); |
202 | 202 | } |