Skip to content

Commit 64fa6e4

Browse files
committed
replace conditional phpseclib aliases with defined classes, support autoloader class maps
1 parent c9d1038 commit 64fa6e4

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

PhpAmqpLib/Helper/BigInteger.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
<?php
2-
2+
// phpcs:ignoreFile
33
namespace PhpAmqpLib\Helper;
44

55
if (class_exists('phpseclib\Math\BigInteger')) {
6-
class_alias('phpseclib\Math\BigInteger', 'PhpAmqpLib\Helper\BigInteger');
6+
class BigInteger extends \phpseclib\Math\BigInteger
7+
{
8+
}
79
} elseif (class_exists('phpseclib3\Math\BigInteger')) {
8-
class_alias('phpseclib3\Math\BigInteger', 'PhpAmqpLib\Helper\BigInteger');
10+
class BigInteger extends \phpseclib3\Math\BigInteger
11+
{
12+
}
913
} else {
1014
throw new \RuntimeException('Cannot find supported phpseclib/phpseclib library');
1115
}

0 commit comments

Comments
 (0)