Skip to content

Commit 608b869

Browse files
committed
refactor: enable level 31: ThrowWithPreviousExceptionRector
1 parent 37e6329 commit 608b869

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

rector.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
*/
1313

1414
use Rector\Caching\ValueObject\Storage\FileCacheStorage;
15-
use Rector\CodeQuality\Rector\Class_\CompleteDynamicPropertiesRector;
1615
use Rector\CodeQuality\Rector\Empty_\SimplifyEmptyCheckOnEmptyArrayRector;
1716
use Rector\CodeQuality\Rector\Expression\InlineIfToExplicitIfRector;
1817
use Rector\CodeQuality\Rector\Foreach_\UnusedForeachValueToArrayKeysRector;
@@ -199,7 +198,6 @@
199198
EmptyOnNullableObjectToInstanceOfRector::class,
200199
DisallowedEmptyRuleFixerRector::class,
201200
PrivatizeFinalClassPropertyRector::class,
202-
CompleteDynamicPropertiesRector::class,
203201
BooleanInIfConditionRuleFixerRector::class,
204202
VersionCompareFuncCallToConstantRector::class,
205203
AddClosureVoidReturnTypeWhereNoReturnRector::class,
@@ -213,4 +211,4 @@
213211
// keep '\\' prefix string on string '\Foo\Bar'
214212
StringClassNameToClassConstantRector::SHOULD_KEEP_PRE_SLASH => true,
215213
])
216-
->withCodeQualityLevel(27);
214+
->withCodeQualityLevel(31);

system/Security/Security.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ protected function derandomize(string $token): string
377377
return bin2hex(hex2bin($value) ^ hex2bin($key));
378378
} catch (ErrorException $e) {
379379
// "hex2bin(): Hexadecimal input string must have an even length"
380-
throw new InvalidArgumentException($e->getMessage());
380+
throw new InvalidArgumentException($e->getMessage(), $e->getCode(), $e);
381381
}
382382
}
383383

0 commit comments

Comments
 (0)