Skip to content

Commit

Permalink
Merge pull request #6991 from heathdutton/feature/php73
Browse files Browse the repository at this point in the history
Support PHP 7.3
  • Loading branch information
dennisameling committed Jan 28, 2020
2 parents 9d595c8 + 029fe55 commit 4e67210
Show file tree
Hide file tree
Showing 7 changed files with 118 additions and 20 deletions.
1 change: 1 addition & 0 deletions .php_cs
Expand Up @@ -18,5 +18,6 @@ return PhpCsFixer\Config::create()
'array_syntax' => [
'syntax' => 'short'
],
'no_unused_imports' => false,
])
->setFinder($finder);
1 change: 1 addition & 0 deletions .travis.yml
Expand Up @@ -9,6 +9,7 @@ php:
- 7.0
- 7.1
- 7.2
- 7.3

cache:
directories:
Expand Down
6 changes: 4 additions & 2 deletions app/bundles/LeadBundle/Entity/LeadListRepository.php
Expand Up @@ -677,7 +677,9 @@ protected function generateSegmentExpression(array $filters, array &$parameters,
$v = $v['value'];
break;
} else {
continue;
// This was previously a "continue" which would act the same as a break in PHP <7.3
// causing the parameter to be set anyway. A continue 2 is more likely the intention.
continue 2;
}
// no break
case is_bool($v):
Expand Down Expand Up @@ -1726,7 +1728,7 @@ public function getListFilterExpr($filters, &$parameters, QueryBuilder $q, $isNo
default:
if (!$column) {
// Column no longer exists so continue
continue;
break;
}

if ('company' === $object) {
Expand Down
2 changes: 1 addition & 1 deletion app/middlewares/VersionCheckMiddleware.php
Expand Up @@ -20,7 +20,7 @@ class VersionCheckMiddleware implements HttpKernelInterface, PrioritizedMiddlewa
const PRIORITY = 10;

const MAUTIC_MINIMUM_PHP = '5.6.19';
const MAUTIC_MAXIMUM_PHP = '7.2.999';
const MAUTIC_MAXIMUM_PHP = '7.3.999';

/**
* @var HttpKernelInterface
Expand Down
10 changes: 8 additions & 2 deletions composer.json
Expand Up @@ -15,7 +15,7 @@
]
},
"require": {
"php": ">=5.6.19 <7.3",
"php": ">=5.6.19 <7.4",

"symfony/console": "~2.8",
"symfony/debug": "~2.8",
Expand Down Expand Up @@ -114,6 +114,7 @@
"ramsey/uuid": "^3.7",
"sendgrid/sendgrid": "~6.0",
"noxlogic/ratelimit-bundle": "^1.11",
"cweagans/composer-patches": "^1.6",
"sensio/framework-extra-bundle": "~3.0"
},
"require-dev": {
Expand Down Expand Up @@ -164,6 +165,11 @@
},
"extra": {
"symfony-app-dir": "app",
"symfony-web-dir": "../"
"symfony-web-dir": "../",
"patches": {
"doctrine/orm": {
"#6991 Support PHP 7.3 without dropping support for 5.6/7.0": "https://github.com/doctrine/doctrine2/commit/07fc401d255a4cdb4a557147d1c8a3fc7a0c718d.diff"
}
}
}
}
116 changes: 102 additions & 14 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion upgrade.php
Expand Up @@ -12,7 +12,7 @@
date_default_timezone_set('UTC');

define('MAUTIC_MINIMUM_PHP', '5.6.19');
define('MAUTIC_MAXIMUM_PHP', '7.2.999');
define('MAUTIC_MAXIMUM_PHP', '7.3.999');

// Are we running the minimum version?
if (version_compare(PHP_VERSION, MAUTIC_MINIMUM_PHP, 'lt')) {
Expand Down

0 comments on commit 4e67210

Please sign in to comment.