diff options
author | n-peugnet <n.peugnet@free.fr> | 2020-04-24 16:36:12 +0200 |
---|---|---|
committer | Vincent Peugnet <33429034+vincent-peugnet@users.noreply.github.com> | 2020-04-25 17:44:38 +0200 |
commit | 385b3f4adf86606e03941171c136d8f2eb2b35c2 (patch) | |
tree | 2231cf04d67a5cae7284364ac5552a321b9a236e /app/class/Colors.php | |
parent | 03d425bdd9a639446ae72ce6556d753f2f162f83 (diff) | |
download | wcms-385b3f4adf86606e03941171c136d8f2eb2b35c2.tar.gz wcms-385b3f4adf86606e03941171c136d8f2eb2b35c2.zip |
fix: most of PHPStan errors
Diffstat (limited to 'app/class/Colors.php')
-rw-r--r-- | app/class/Colors.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/app/class/Colors.php b/app/class/Colors.php index 234adb2..ffa56b6 100644 --- a/app/class/Colors.php +++ b/app/class/Colors.php @@ -5,7 +5,7 @@ namespace Wcms; class Colors extends Item { - protected $file = MODEL::CSS_DIR . 'tagcolors.css'; + protected $file = Model::CSS_DIR . 'tagcolors.css'; protected $rawcss = ""; @@ -27,7 +27,7 @@ class Colors extends Item public function readcssfile(): bool { - if (MODEL::dircheck(MODEL::CSS_DIR) && file_exists($this->file)) { + if (Model::dircheck(Model::CSS_DIR) && file_exists($this->file)) { $this->rawcss = file_get_contents($this->file); return true; } else { @@ -53,7 +53,7 @@ class Colors extends Item /** * Transform a CSS string in a array of `tag => background-color` * - * @return array Ouput array using TAG as key and Hex Color as value + * @return bool Ouput array using TAG as key and Hex Color as value */ public function parsetagcss() { @@ -79,7 +79,7 @@ class Colors extends Item public function writecssfile() { - if (MODEL::dircheck(MODEL::CSS_DIR)) { + if (Model::dircheck(Model::CSS_DIR)) { return file_put_contents($this->file, $this->rawcss); } } @@ -90,7 +90,7 @@ class Colors extends Item foreach ($this->tagcolor as $tag => $color) { $i = '<input type="color" name="tagcolor[' . $tag . ']" value="' . $color . '" id="color_' . $tag . '">'; $l = '<label for="color_' . $tag . '" >' . $tag . '</label>'; - $html .= '\n<li>' . $i . $l . '</li>'; + $html .= "\n<li>" . $i . $l . '</li>'; } $html .= PHP_EOL . '</ul>'; return $html; |