Make all the tests pass in PHP5 and 7
This commit is contained in:
parent
1b5003727d
commit
89ec9f4a88
@ -25,6 +25,7 @@
|
||||
"ext-json": "*",
|
||||
"doctrine/annotations": "1.2.7",
|
||||
"doctrine/cache": "1.6.2",
|
||||
"doctrine/collections": "1.3.0",
|
||||
"doctrine/common": "2.6.2",
|
||||
"doctrine/instantiator": "1.0.5",
|
||||
"doctrine/orm": "2.5.14",
|
||||
|
19
composer.lock
generated
19
composer.lock
generated
@ -4,7 +4,7 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "b624fbe63ec43847c5e8cd411676d072",
|
||||
"content-hash": "e4bf44b9498b87159a1ec70b7d6225bd",
|
||||
"packages": [
|
||||
{
|
||||
"name": "doctrine/annotations",
|
||||
@ -146,29 +146,28 @@
|
||||
},
|
||||
{
|
||||
"name": "doctrine/collections",
|
||||
"version": "v1.5.0",
|
||||
"version": "v1.3.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/collections.git",
|
||||
"reference": "a01ee38fcd999f34d9bfbcee59dbda5105449cbf"
|
||||
"reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/collections/zipball/a01ee38fcd999f34d9bfbcee59dbda5105449cbf",
|
||||
"reference": "a01ee38fcd999f34d9bfbcee59dbda5105449cbf",
|
||||
"url": "https://api.github.com/repos/doctrine/collections/zipball/6c1e4eef75f310ea1b3e30945e9f06e652128b8a",
|
||||
"reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^7.1"
|
||||
"php": ">=5.3.2"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/coding-standard": "~0.1@dev",
|
||||
"phpunit/phpunit": "^5.7"
|
||||
"phpunit/phpunit": "~4.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.3.x-dev"
|
||||
"dev-master": "1.2.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@ -209,7 +208,7 @@
|
||||
"collections",
|
||||
"iterator"
|
||||
],
|
||||
"time": "2017-07-22T10:37:32+00:00"
|
||||
"time": "2015-04-14T22:21:58+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/common",
|
||||
|
@ -3,9 +3,6 @@ namespace ActivityPub\Utils;
|
||||
|
||||
class RandomProvider
|
||||
{
|
||||
const ID_CHARS = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ';
|
||||
const ID_CHARS_LEN = 62;
|
||||
|
||||
/**
|
||||
* Generates a random alphanumeric string of length $length
|
||||
*
|
||||
@ -17,7 +14,7 @@ class RandomProvider
|
||||
{
|
||||
$str = '';
|
||||
for ( $i = 0; $i < $length; $i++ ) {
|
||||
$str = $str . self::ID_CHARS[rand( 0, self::ID_CHARS_LEN - 1)];
|
||||
$str = $str . '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'[rand( 0, 61 )];
|
||||
}
|
||||
return $str;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user