Skip to content

Commit

Permalink
Merge 4.x into 5.x
Browse files Browse the repository at this point in the history
  • Loading branch information
SonataCI authored Dec 8, 2024
2 parents f4013bf + 1f68177 commit aa6afa9
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 87 deletions.
65 changes: 0 additions & 65 deletions .github/workflows/test_orm_3.yaml

This file was deleted.

36 changes: 18 additions & 18 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,24 +25,24 @@
],
"homepage": "https://docs.sonata-project.org/projects/SonataDoctrineORMAdminBundle",
"require": {
"php": "^8.0",
"php": "^8.1",
"doctrine/dbal": "^3.4 || ^4.0",
"doctrine/doctrine-bundle": "^2.10",
"doctrine/orm": "^2.17 || ^3.0",
"doctrine/persistence": "^3.0.2",
"sonata-project/admin-bundle": "^4.18",
"sonata-project/admin-bundle": "^4.34",
"sonata-project/exporter": "^2.0 || ^3.0",
"sonata-project/form-extensions": "^1.19 || ^2.0",
"symfony/config": "^5.4 || ^6.2 || ^7.0",
"symfony/console": "^5.4 || ^6.2 || ^7.0",
"symfony/dependency-injection": "^5.4 || ^6.2 || ^7.0",
"symfony/doctrine-bridge": "^5.4 || ^6.2 || ^7.0",
"symfony/form": "^5.4 || ^6.2 || ^7.0",
"symfony/framework-bundle": "^5.4 || ^6.2 || ^7.0",
"symfony/http-foundation": "^5.4 || ^6.2 || ^7.0",
"symfony/http-kernel": "^5.4 || ^6.2 || ^7.0",
"symfony/options-resolver": "^5.4 || ^6.2 || ^7.0",
"symfony/property-access": "^5.4 || ^6.2 || ^7.0",
"symfony/config": "^6.4 || ^7.1",
"symfony/console": "^6.4 || ^7.1",
"symfony/dependency-injection": "^6.4 || ^7.1",
"symfony/doctrine-bridge": "^6.4 || ^7.1",
"symfony/form": "^6.4 || ^7.1",
"symfony/framework-bundle": "^6.4 || ^7.1",
"symfony/http-foundation": "^6.4 || ^7.1",
"symfony/http-kernel": "^6.4 || ^7.1",
"symfony/options-resolver": "^6.4 || ^7.1",
"symfony/property-access": "^6.4 || ^7.1",
"symfony/security-acl": "^3.0",
"twig/twig": "^3.0"
},
Expand All @@ -63,13 +63,13 @@
"rector/rector": "^1.1",
"sonata-project/block-bundle": "^5.0",
"sonata-project/entity-audit-bundle": "^1.1",
"symfony/browser-kit": "^5.4 || ^6.2 || ^7.0",
"symfony/css-selector": "^5.4 || ^6.2 || ^7.0",
"symfony/browser-kit": "^6.4 || ^7.1",
"symfony/css-selector": "^6.4 || ^7.1",
"symfony/panther": "^2.0.1",
"symfony/phpunit-bridge": "^6.2 || ^7.0",
"symfony/templating": "^5.4 || ^6.2 || ^7.0",
"symfony/uid": "^5.4 || ^6.2 || ^7.0",
"symfony/yaml": "^5.4 || ^6.2 || ^7.0",
"symfony/phpunit-bridge": "^6.4 || ^7.1",
"symfony/templating": "^6.4 || ^7.1",
"symfony/uid": "^6.4 || ^7.1",
"symfony/yaml": "^6.4 || ^7.1",
"vimeo/psalm": "^5.7",
"weirdan/doctrine-psalm-plugin": "^2.0"
},
Expand Down
4 changes: 4 additions & 0 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@

use Rector\Config\RectorConfig;
use Rector\Php70\Rector\FunctionLike\ExceptionHandlerTypehintRector;
use Rector\Php81\Rector\FuncCall\NullToStrictStringFuncCallArgRector;
use Rector\Php81\Rector\Property\ReadOnlyPropertyRector;
use Rector\PHPUnit\CodeQuality\Rector\Class_\NarrowUnusedSetUpDefinedPropertyRector;
use Rector\PHPUnit\CodeQuality\Rector\Class_\PreferPHPUnitThisCallRector;
use Rector\PHPUnit\Set\PHPUnitSetList;
Expand All @@ -40,6 +42,8 @@
$rectorConfig->importShortClasses(false);
$rectorConfig->skip([
ExceptionHandlerTypehintRector::class,
ReadOnlyPropertyRector::class,
NullToStrictStringFuncCallArgRector::class,
PreferPHPUnitThisCallRector::class,
NarrowUnusedSetUpDefinedPropertyRector::class,
]);
Expand Down
2 changes: 1 addition & 1 deletion src/Exporter/DataSource.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ private function findFieldName(ProxyQueryInterface $query, string $alias): ?stri
$joinAlias = $joinPart->getAlias();

if ($joinAlias === $alias) {
$joinParts = explode('.', $join);
$joinParts = explode('.', (string) $join);

return end($joinParts);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Filter/ModelFilter.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ private function getParentAlias(ProxyQueryInterface $query, string $alias): stri
if (isset($joins[$rootAlias])) {
foreach ($joins[$rootAlias] as $join) {
if ($join->getAlias() === $alias) {
$parts = explode('.', $join->getJoin());
$parts = explode('.', (string) $join->getJoin());
$parentAlias = $parts[0];

break;
Expand Down
2 changes: 1 addition & 1 deletion src/Util/SmartPaginatorFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ private static function hasOrderByWithToManyAssociation(ProxyQueryInterface $pro
foreach ($orderByParts as $orderByPart) {
foreach ($orderByPart->getParts() as $part) {
foreach ($joinAliases as $joinAlias) {
if (str_starts_with($part, $joinAlias.'.')) {
if (str_starts_with((string) $part, $joinAlias.'.')) {
return true;
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Filter/CallbackFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function testFilterMethod(): void

$filter = new CallbackFilter();
$filter->initialize('field_name', [
'callback' => [$this, 'customCallback'],
'callback' => $this->customCallback(...),
]);

$filter->filter($proxyQuery, 'alias', 'field', FilterData::fromArray(['value' => 'myValue']));
Expand Down

0 comments on commit aa6afa9

Please sign in to comment.