@@ -41,7 +41,7 @@ abstract public static function fromString(string $uid): static;
41
41
public static function fromBinary (string $ uid ): static
42
42
{
43
43
if (16 !== \strlen ($ uid )) {
44
- throw new InvalidArgumentException ('Invalid binary uid provided. ' );
44
+ throw new InvalidArgumentException ($ uid , 'Invalid binary uid provided. ' );
45
45
}
46
46
47
47
return static ::fromString ($ uid );
@@ -53,7 +53,7 @@ public static function fromBinary(string $uid): static
53
53
public static function fromBase58 (string $ uid ): static
54
54
{
55
55
if (22 !== \strlen ($ uid )) {
56
- throw new InvalidArgumentException ('Invalid base-58 uid provided. ' );
56
+ throw new InvalidArgumentException ($ uid , 'Invalid base-58 uid provided. ' );
57
57
}
58
58
59
59
return static ::fromString ($ uid );
@@ -65,7 +65,7 @@ public static function fromBase58(string $uid): static
65
65
public static function fromBase32 (string $ uid ): static
66
66
{
67
67
if (26 !== \strlen ($ uid )) {
68
- throw new InvalidArgumentException ('Invalid base-32 uid provided. ' );
68
+ throw new InvalidArgumentException ($ uid , 'Invalid base-32 uid provided. ' );
69
69
}
70
70
71
71
return static ::fromString ($ uid );
@@ -79,7 +79,7 @@ public static function fromBase32(string $uid): static
79
79
public static function fromRfc4122 (string $ uid ): static
80
80
{
81
81
if (36 !== \strlen ($ uid )) {
82
- throw new InvalidArgumentException ('Invalid RFC4122 uid provided. ' );
82
+ throw new InvalidArgumentException ($ uid , 'Invalid RFC4122 uid provided. ' );
83
83
}
84
84
85
85
return static ::fromString ($ uid );
0 commit comments