Skip to content

Commit

Permalink
Add RangeException to Base64UrlSafe (#577)
Browse files Browse the repository at this point in the history
* Add RangeException to Base64UrlSafe

The code in src/Library/Core/Util/Base64UrlSafe.php has been updated to include the use of RangeException. This will further expand its capability in terms of handling exceptional scenarios.
  • Loading branch information
Spomky authored Jul 2, 2024
1 parent 1fe7ca8 commit 1e9f8bf
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 12 deletions.
4 changes: 2 additions & 2 deletions .gitsplit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,5 @@ splits:
target: "https://${GH_TOKEN}@github.com/web-token/signature-pack.git"

origins:
- ^\d+\.\d+\.x$
- ^\d+\.\d+\.\d+$
- ^(1|2|3)\.\d+\.x$
- ^(1|2|3)\.\d+\.\d+$
10 changes: 0 additions & 10 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -1673,11 +1673,6 @@ parameters:
count: 2
path: src/Library/Core/Util/Base64UrlSafe.php

-
message: "#^Instantiated class Jose\\\\Component\\\\Core\\\\Util\\\\RangeException not found\\.$#"
count: 3
path: src/Library/Core/Util/Base64UrlSafe.php

-
message: "#^Method Jose\\\\Component\\\\Core\\\\Util\\\\Base64UrlSafe\\:\\:safeSubstr\\(\\) has parameter \\$length with no type specified\\.$#"
count: 1
Expand All @@ -1688,11 +1683,6 @@ parameters:
count: 2
path: src/Library/Core/Util/Base64UrlSafe.php

-
message: "#^Throwing object of an unknown class Jose\\\\Component\\\\Core\\\\Util\\\\RangeException\\.$#"
count: 3
path: src/Library/Core/Util/Base64UrlSafe.php

-
message: "#^Variable \\$i might not be defined\\.$#"
count: 2
Expand Down
2 changes: 2 additions & 0 deletions src/Library/Core/Util/Base64UrlSafe.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
* SOFTWARE.
*/

use RangeException;

/**
* @readonly
*/
Expand Down

0 comments on commit 1e9f8bf

Please sign in to comment.