Skip to content

Commit

Permalink
Prepare for ramsey/uuid 4.x support
Browse files Browse the repository at this point in the history
  • Loading branch information
ramsey authored and Pascal de Vink committed Mar 25, 2020
1 parent 5bc402b commit 6f994a2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"require": {
"php": "^7.1",
"moontoast/math": "^1.1",
"ramsey/uuid": "^3.0"
"ramsey/uuid": "^3 | ^4"
},
"require-dev": {
"phpunit/phpunit": "^6.0|^7.0"
Expand Down
3 changes: 1 addition & 2 deletions src/ShortUuid.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,7 @@ public static function uuid5(string $ns, string $name) : string
*/
public function encode(UuidInterface $uuid) : string
{
/** @var BigNumber $uuidInteger */
$uuidInteger = $uuid->getInteger();
$uuidInteger = new BigNumber((string) $uuid->getInteger());
return $this->numToString($uuidInteger);
}

Expand Down

0 comments on commit 6f994a2

Please sign in to comment.