diff --git a/.gitattributes b/.gitattributes index 9645b77e9..282650056 100644 --- a/.gitattributes +++ b/.gitattributes @@ -8,4 +8,5 @@ docker-compose.yml export-ignore phpstan.neon export-ignore phpunit.xml export-ignore +test/ export-ignore tests/ export-ignore diff --git a/lib/config/sfConfigCache.class.php b/lib/config/sfConfigCache.class.php index e0b5ca871..b02c38e03 100644 --- a/lib/config/sfConfigCache.class.php +++ b/lib/config/sfConfigCache.class.php @@ -157,9 +157,9 @@ public function import($config, $once = true, $optional = false) /** * Registers a configuration handler. * - * @param string $handler The handler to use when parsing a configuration file - * @param class $class A configuration handler class - * @param string $params An array of options for the handler class initialization + * @param string $handler The handler to use when parsing a configuration file + * @param class-string $class A configuration handler class + * @param string[] $params An array of options for the handler class initialization */ public function registerConfigHandler($handler, $class, $params = []) { diff --git a/lib/helper/TextHelper.php b/lib/helper/TextHelper.php index bbe3759a8..ed9d85a62 100644 --- a/lib/helper/TextHelper.php +++ b/lib/helper/TextHelper.php @@ -184,7 +184,7 @@ function simple_format_text($text, $options = []) { $css = (isset($options['class'])) ? ' class="'.$options['class'].'"' : ''; - $text = preg_replace('/(\r\n|\r)/', "\n", $text); // lets make them newlines crossplatform + $text = preg_replace('/(\r\n|\r)/', "\n", $text); // lets make them newlines crossplatform $text = preg_replace('/\n{2,}/', "

", $text); // turn two and more newlines into paragraph // turn single newline into
diff --git a/lib/task/sfTask.class.php b/lib/task/sfTask.class.php index 1e35eb621..21ff5f64e 100644 --- a/lib/task/sfTask.class.php +++ b/lib/task/sfTask.class.php @@ -658,7 +658,7 @@ protected function usageCloseToLimit($usage, $warning_when_remaining) protected function convertIntToUnit($size) { - $unit = ['b', 'kb', 'mb', 'gb', 'tb', 'pb']; + $unit = ['B', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB']; $i = floor(log($size, 1024)); return @round($size / pow(1024, $i), 2)." {$unit[$i]}";