diff --git a/.github/workflows/phpunit.yml b/.github/workflows/phpunit.yml index 67a44a323272..67440856c85b 100644 --- a/.github/workflows/phpunit.yml +++ b/.github/workflows/phpunit.yml @@ -13,7 +13,7 @@ jobs: strategy: matrix: operating-system: ['ubuntu-18.04', 'ubuntu-20.04'] - php-versions: ['7.4'] + php-versions: ['7.3','7.4','8.0'] phpunit-versions: ['latest'] env: diff --git a/app/Utils/Traits/CompanySettingsSaver.php b/app/Utils/Traits/CompanySettingsSaver.php index 3cc14551303c..00fb5bfb8390 100644 --- a/app/Utils/Traits/CompanySettingsSaver.php +++ b/app/Utils/Traits/CompanySettingsSaver.php @@ -220,14 +220,14 @@ trait CompanySettingsSaver switch ($key) { case 'int': case 'integer': - return ctype_digit(strval(abs($value))); + return ctype_digit(strval(abs((int)$value))); // return is_int($value) || ctype_digit(strval(abs($value))); case 'real': case 'float': case 'double': return is_float($value) || is_numeric(strval($value)); case 'string': - return method_exists($value, '__toString') || is_null($value) || is_string($value); + return (is_string($value) && method_exists($value, '__toString')) || is_null($value) || is_string($value); //return is_null($value) || is_string($value); case 'bool': case 'boolean': diff --git a/composer.lock b/composer.lock index 25ba157a2400..9db957d61e1b 100644 --- a/composer.lock +++ b/composer.lock @@ -51,16 +51,16 @@ }, { "name": "aws/aws-sdk-php", - "version": "3.176.5", + "version": "3.176.8", "source": { "type": "git", "url": "https://github.com/aws/aws-sdk-php.git", - "reference": "45d69a8da4f55879f8a24b0b659a5bc7ad077725" + "reference": "776b944988167fa3d563d2cbc5fcb6763424a9f0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/45d69a8da4f55879f8a24b0b659a5bc7ad077725", - "reference": "45d69a8da4f55879f8a24b0b659a5bc7ad077725", + "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/776b944988167fa3d563d2cbc5fcb6763424a9f0", + "reference": "776b944988167fa3d563d2cbc5fcb6763424a9f0", "shasum": "" }, "require": { @@ -135,9 +135,9 @@ "support": { "forum": "https://forums.aws.amazon.com/forum.jspa?forumID=80", "issues": "https://github.com/aws/aws-sdk-php/issues", - "source": "https://github.com/aws/aws-sdk-php/tree/3.176.5" + "source": "https://github.com/aws/aws-sdk-php/tree/3.176.8" }, - "time": "2021-03-31T18:15:22+00:00" + "time": "2021-04-05T18:16:29+00:00" }, { "name": "bacon/bacon-qr-code", @@ -641,16 +641,16 @@ }, { "name": "composer/composer", - "version": "2.0.11", + "version": "2.0.12", "source": { "type": "git", "url": "https://github.com/composer/composer.git", - "reference": "a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9" + "reference": "6c12ce263da71641903e399c3ce8ecb08fd375fb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9", - "reference": "a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9", + "url": "https://api.github.com/repos/composer/composer/zipball/6c12ce263da71641903e399c3ce8ecb08fd375fb", + "reference": "6c12ce263da71641903e399c3ce8ecb08fd375fb", "shasum": "" }, "require": { @@ -718,7 +718,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/composer/issues", - "source": "https://github.com/composer/composer/tree/2.0.11" + "source": "https://github.com/composer/composer/tree/2.0.12" }, "funding": [ { @@ -734,7 +734,7 @@ "type": "tidelift" } ], - "time": "2021-02-24T13:57:23+00:00" + "time": "2021-04-01T08:14:59+00:00" }, { "name": "composer/semver", @@ -2045,7 +2045,7 @@ }, { "name": "google/apiclient-services", - "version": "v0.166.0", + "version": "v0.167.0", "source": { "type": "git", "url": "https://github.com/googleapis/google-api-php-client-services.git", @@ -2080,7 +2080,7 @@ ], "support": { "issues": "https://github.com/googleapis/google-api-php-client-services/issues", - "source": "https://github.com/googleapis/google-api-php-client-services/tree/v0.166.0" + "source": "https://github.com/googleapis/google-api-php-client-services/tree/v0.167.0" }, "time": "2021-03-22T11:26:04+00:00" }, @@ -3881,16 +3881,16 @@ }, { "name": "livewire/livewire", - "version": "v2.4.1", + "version": "v2.4.2", "source": { "type": "git", "url": "https://github.com/livewire/livewire.git", - "reference": "b0cb782674673a67ddfd5910d2fcb5308bb32857" + "reference": "2495387841a3eb03ac62b2c984ccd2574303285b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/livewire/livewire/zipball/b0cb782674673a67ddfd5910d2fcb5308bb32857", - "reference": "b0cb782674673a67ddfd5910d2fcb5308bb32857", + "url": "https://api.github.com/repos/livewire/livewire/zipball/2495387841a3eb03ac62b2c984ccd2574303285b", + "reference": "2495387841a3eb03ac62b2c984ccd2574303285b", "shasum": "" }, "require": { @@ -3941,7 +3941,7 @@ "description": "A front-end framework for Laravel.", "support": { "issues": "https://github.com/livewire/livewire/issues", - "source": "https://github.com/livewire/livewire/tree/v2.4.1" + "source": "https://github.com/livewire/livewire/tree/v2.4.2" }, "funding": [ { @@ -3949,7 +3949,7 @@ "type": "github" } ], - "time": "2021-03-22T14:03:36+00:00" + "time": "2021-04-04T15:46:50+00:00" }, { "name": "maennchen/zipstream-php", @@ -5645,23 +5645,22 @@ }, { "name": "predis/predis", - "version": "v1.1.6", + "version": "v1.1.7", "source": { "type": "git", "url": "https://github.com/predis/predis.git", - "reference": "9930e933c67446962997b05201c69c2319bf26de" + "reference": "b240daa106d4e02f0c5b7079b41e31ddf66fddf8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/predis/predis/zipball/9930e933c67446962997b05201c69c2319bf26de", - "reference": "9930e933c67446962997b05201c69c2319bf26de", + "url": "https://api.github.com/repos/predis/predis/zipball/b240daa106d4e02f0c5b7079b41e31ddf66fddf8", + "reference": "b240daa106d4e02f0c5b7079b41e31ddf66fddf8", "shasum": "" }, "require": { "php": ">=5.3.9" }, "require-dev": { - "cweagans/composer-patches": "^1.6", "phpunit/phpunit": "~4.8" }, "suggest": { @@ -5669,18 +5668,6 @@ "ext-phpiredis": "Allows faster serialization and deserialization of the Redis protocol" }, "type": "library", - "extra": { - "composer-exit-on-patch-failure": true, - "patches": { - "phpunit/phpunit-mock-objects": { - "Fix PHP 7 and 8 compatibility": "./tests/phpunit_mock_objects.patch" - }, - "phpunit/phpunit": { - "Fix PHP 7 compatibility": "./tests/phpunit_php7.patch", - "Fix PHP 8 compatibility": "./tests/phpunit_php8.patch" - } - } - }, "autoload": { "psr-4": { "Predis\\": "src/" @@ -5712,7 +5699,7 @@ ], "support": { "issues": "https://github.com/predis/predis/issues", - "source": "https://github.com/predis/predis/tree/v1.1.6" + "source": "https://github.com/predis/predis/tree/v1.1.7" }, "funding": [ { @@ -5720,7 +5707,7 @@ "type": "github" } ], - "time": "2020-09-11T19:18:05+00:00" + "time": "2021-04-04T19:34:46+00:00" }, { "name": "psr/cache",