summaryrefslogtreecommitdiffstats
path: root/src/Utils/Formatter.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/Utils/Formatter.php')
-rw-r--r--src/Utils/Formatter.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Utils/Formatter.php b/src/Utils/Formatter.php
index 2d2ca40..94d908c 100644
--- a/src/Utils/Formatter.php
+++ b/src/Utils/Formatter.php
@@ -1,8 +1,8 @@
<?php
-
/**
* Utilities that are used for formatting queries.
*/
+declare(strict_types=1);
namespace PhpMyAdmin\SqlParser\Utils;
@@ -500,7 +500,7 @@ class Formatter
// No space after . (
|| ($curr->type === Token::TYPE_OPERATOR && ($curr->value === '.' || $curr->value === ',' || $curr->value === '(' || $curr->value === ')'))
// No space before . , ( )
- || $curr->type === Token::TYPE_DELIMITER && mb_strlen($curr->value, 'UTF-8') < 2
+ || $curr->type === Token::TYPE_DELIMITER && mb_strlen((string) $curr->value, 'UTF-8') < 2
)
) {
$ret .= ' ';
@@ -706,7 +706,7 @@ class Formatter
}
// Keeping track of this group's length.
- $length += mb_strlen($list->tokens[$idx]->value, 'UTF-8');
+ $length += mb_strlen((string) $list->tokens[$idx]->value, 'UTF-8');
}
return $length;