diff options
author | Javier Marín <javier@marinros.com> | 2023-03-21 18:10:38 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-21 18:10:38 +0300 |
commit | e1cca194c57cf242fd8635b2e72e11e990279c95 (patch) | |
tree | a2220decdc35e06c10b8e3b2e9893a464cb9bc79 /src | |
parent | 1b8d71d953d2ad9c9eb97d1fed9fe4ed4f8e83d3 (diff) |
fix: strcmp(): Passing null to parameter #1 ($string1) of type string is deprecated (#123)v2.3.4
Diffstat (limited to 'src')
-rw-r--r-- | src/NXP/MathExecutor.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/NXP/MathExecutor.php b/src/NXP/MathExecutor.php index 84dd3d9..2a3fd72 100644 --- a/src/NXP/MathExecutor.php +++ b/src/NXP/MathExecutor.php @@ -382,8 +382,8 @@ class MathExecutor '%' => [static fn($a, $b) => $a % $b, 180, false], '&&' => [static fn($a, $b) => $a && $b, 100, false], '||' => [static fn($a, $b) => $a || $b, 90, false], - '==' => [static fn($a, $b) => \is_string($a) || \is_string($b) ? 0 == \strcmp($a, $b) : $a == $b, 140, false], - '!=' => [static fn($a, $b) => \is_string($a) || \is_string($b) ? 0 != \strcmp($a, $b) : $a != $b, 140, false], + '==' => [static fn($a, $b) => \is_string($a) || \is_string($b) ? 0 == \strcmp((string)$a, (string)$b) : $a == $b, 140, false], + '!=' => [static fn($a, $b) => \is_string($a) || \is_string($b) ? 0 != \strcmp((string)$a, (string)$b) : $a != $b, 140, false], '>=' => [static fn($a, $b) => $a >= $b, 150, false], '>' => [static fn($a, $b) => $a > $b, 150, false], '<=' => [static fn($a, $b) => $a <= $b, 150, false], |