Skip to content

Commit 04c1941

Browse files
committed
fix: Update dependencies (fix phpstan/rector issues)
1 parent 716aa24 commit 04c1941

File tree

5 files changed

+16
-16
lines changed

5 files changed

+16
-16
lines changed

composer.json

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,16 @@
1313
"php": "^8.2"
1414
},
1515
"require-dev": {
16-
"brainbits/phpcs-standard": "^7.0.2",
17-
"brainbits/phpstan-rules": "^3.1.2",
18-
"ergebnis/phpstan-rules": "^2.5.2",
19-
"thecodingmachine/phpstan-safe-rule": "^1.2.0",
20-
"thecodingmachine/phpstan-strict-rules": "^1.0.0",
21-
"phpstan/phpstan-phpunit": "^1.4.2",
22-
"squizlabs/php_codesniffer": "^3.11.3",
23-
"phpstan/phpstan": "^1.12.19",
24-
"phpstan/phpstan-strict-rules": "^1.6.2",
25-
"phpunit/phpunit": "^11.5.10",
26-
"rector/rector": "^1.2.10"
16+
"brainbits/phpcs-standard": "^8.0.0",
17+
"brainbits/phpstan-rules": "^4.0.0",
18+
"ergebnis/phpstan-rules": "^2.8.0",
19+
"thecodingmachine/phpstan-safe-rule": "^1.4.0",
20+
"phpstan/phpstan-phpunit": "^2.0.6",
21+
"squizlabs/php_codesniffer": "^3.12.2",
22+
"phpstan/phpstan": "^2.1.14",
23+
"phpstan/phpstan-strict-rules": "^2.0.4",
24+
"phpunit/phpunit": "^12.1.4",
25+
"rector/rector": "^2.0.15"
2726
},
2827
"autoload": {
2928
"psr-4": {

phpstan.neon.dist

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,3 @@ includes:
2121
- vendor/phpstan/phpstan-phpunit/extension.neon
2222
- vendor/phpstan/phpstan-phpunit/rules.neon
2323
- vendor/phpstan/phpstan-strict-rules/rules.neon
24-
- vendor/thecodingmachine/phpstan-strict-rules/phpstan-strict-rules.neon

src/InvalidValue.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ private static function withMessage(string $message): self
2626
$line = $trace['line'] ?? null;
2727

2828
if ($file !== null && $line !== null && !str_contains($file, __DIR__)) {
29-
$me->message = sprintf('%s in %s:%s', $me->message, basename($file), $line);
29+
$me->message = sprintf('%s in %s:%s', $message, basename($file), $line);
3030
break;
3131
}
3232
}

src/NotConvertable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ private static function withMessage(string $message): self
4747
$line = $trace['line'] ?? null;
4848

4949
if ($file !== null && $line !== null && !str_contains($file, __DIR__)) {
50-
$me->message = sprintf('%s in %s:%s', $me->message, basename($file), $line);
50+
$me->message = sprintf('%s in %s:%s', $message, basename($file), $line);
5151
break;
5252
}
5353
}

src/TypeGuard.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,13 @@ final class TypeGuard
2121

2222
private string $dateTimeFormat = 'c';
2323

24+
private static TypeGuard $typeGuard;
25+
2426
public static function instance(): self
2527
{
26-
static $instance = new self();
28+
self::$typeGuard ??= new self();
2729

28-
return $instance;
30+
return self::$typeGuard;
2931
}
3032

3133
/** @return ($value is null ? null : bool) */

0 commit comments

Comments
 (0)