Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
184 changes: 11 additions & 173 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -630,12 +630,6 @@ parameters:
count: 1
path: src/bundle/Core/DependencyInjection/Configuration/ConfigResolver.php

-
message: '#^Offset ''function'' on array\{function\: string, line\?\: int, file\?\: string, class\?\: class\-string, type\?\: ''\-\>''\|''\:\:'', args\?\: array\<mixed\>, object\?\: object\} in isset\(\) always exists and is not nullable\.$#'
identifier: isset.offset
count: 1
path: src/bundle/Core/DependencyInjection/Configuration/ConfigResolver.php

-
message: '#^Parameter \#1 \$string of function strtolower expects string, string\|null given\.$#'
identifier: argument.type
Expand Down Expand Up @@ -5929,7 +5923,7 @@ parameters:
path: src/lib/FieldType/Author/Type.php

-
message: '#^Method Ibexa\\Core\\FieldType\\Author\\Type\:\:toHash\(\) should return list\<array\{id\: int, name\: string, email\: string\}\> but returns array\<int, array\{id\: int, name\: string, email\: string\}\>\.$#'
message: '#^Method Ibexa\\Core\\FieldType\\Author\\Type\:\:toHash\(\) should return list\<array\{id\: int, name\: string, email\: string\}\> but returns array\<int, non\-empty\-array\>\.$#'
identifier: return.type
count: 1
path: src/lib/FieldType/Author/Type.php
Expand Down Expand Up @@ -6258,12 +6252,6 @@ parameters:
count: 1
path: src/lib/FieldType/BinaryFile/Type.php

-
message: '#^Method Ibexa\\Core\\FieldType\\BinaryFile\\Type\:\:completeValue\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: src/lib/FieldType/BinaryFile/Type.php

-
message: '#^Method Ibexa\\Core\\FieldType\\BinaryFile\\Type\:\:createValue\(\) has parameter \$inputValue with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -7164,12 +7152,6 @@ parameters:
count: 1
path: src/lib/FieldType/Media/Type.php

-
message: '#^Method Ibexa\\Core\\FieldType\\Media\\Type\:\:completeValue\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: src/lib/FieldType/Media/Type.php

-
message: '#^Method Ibexa\\Core\\FieldType\\Media\\Type\:\:createValue\(\) has parameter \$inputValue with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -10626,12 +10608,6 @@ parameters:
count: 1
path: src/lib/Persistence/Cache/PersistenceLogger.php

-
message: '#^Offset ''class'' might not exist on array\{function\: string, line\?\: int, file\?\: string, class\?\: class\-string, type\?\: ''\-\>''\|''\:\:'', args\?\: array\<mixed\>, object\?\: object\}\.$#'
identifier: offsetAccess.notFound
count: 2
path: src/lib/Persistence/Cache/PersistenceLogger.php

-
message: '#^Property Ibexa\\Core\\Persistence\\Cache\\PersistenceLogger\:\:\$calls type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -11232,18 +11208,6 @@ parameters:
count: 1
path: src/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryConverter.php

-
message: '#^Parameter \#2 \$array of function implode expects array\|null, array\|bool\|float\|int\|string given\.$#'
identifier: argument.type
count: 1
path: src/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryConverter.php

-
message: '#^Parameter \#2 \$array of function implode expects array\|null, array\|float\|int\<min, \-1\>\|int\<1, max\>\|string\|true given\.$#'
identifier: argument.type
count: 1
path: src/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryConverter.php

-
message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageFieldValue\:\:\$sortKeyString \(string\) does not accept bool\|float\|int\|string\|null\.$#'
identifier: assign.propertyType
Expand Down Expand Up @@ -11496,12 +11460,6 @@ parameters:
count: 1
path: src/lib/Persistence/Legacy/Content/FieldValue/Converter/ImageConverter.php

-
message: '#^Cannot access property \$nodeValue on \(TNode of DOMNode\)\|null\.$#'
identifier: property.nonObject
count: 1
path: src/lib/Persistence/Legacy/Content/FieldValue/Converter/ImageConverter.php

-
message: '#^Cannot call method getAttribute\(\) on DOMElement\|null\.$#'
identifier: method.nonObject
Expand Down Expand Up @@ -12660,12 +12618,6 @@ parameters:
count: 1
path: src/lib/Persistence/Legacy/Content/Language/MaskGenerator.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:create\(\) has parameter \$parentNode with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
count: 1
path: src/lib/Persistence/Legacy/Content/Location/Gateway.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:getBasicNodeData\(\) return type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -12756,12 +12708,6 @@ parameters:
count: 1
path: src/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabase.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabase\:\:create\(\) has parameter \$parentNode with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
count: 1
path: src/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabase.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabase\:\:createNodeQueryBuilder\(\) has parameter \$columns with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -12906,12 +12852,6 @@ parameters:
count: 8
path: src/lib/Persistence/Legacy/Content/Location/Gateway/ExceptionConversion.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\ExceptionConversion\:\:create\(\) has parameter \$parentNode with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
count: 1
path: src/lib/Persistence/Legacy/Content/Location/Gateway/ExceptionConversion.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\ExceptionConversion\:\:getBasicNodeData\(\) return type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -15468,30 +15408,6 @@ parameters:
count: 1
path: src/lib/Persistence/Legacy/SharedGateway/DatabasePlatform/SqliteGateway.php

-
message: '#^Argument of an invalid type array\<Ibexa\\Core\\Persistence\\Legacy\\SharedGateway\\Gateway\>\|iterable supplied for foreach, only iterables are supported\.$#'
identifier: foreach.nonIterable
count: 1
path: src/lib/Persistence/Legacy/SharedGateway/GatewayFactory.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\SharedGateway\\GatewayFactory\:\:__construct\(\) has parameter \$gateways with no value type specified in iterable type iterable\.$#'
identifier: missingType.iterableValue
count: 1
path: src/lib/Persistence/Legacy/SharedGateway/GatewayFactory.php

-
message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\SharedGateway\\GatewayFactory\:\:\$gateways \(array\<Ibexa\\Core\\Persistence\\Legacy\\SharedGateway\\Gateway\>\|iterable\) does not accept iterable\.$#'
identifier: assign.propertyType
count: 1
path: src/lib/Persistence/Legacy/SharedGateway/GatewayFactory.php

-
message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\SharedGateway\\GatewayFactory\:\:\$gateways has unknown class iterable as its type\.$#'
identifier: class.notFound
count: 1
path: src/lib/Persistence/Legacy/SharedGateway/GatewayFactory.php

-
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Token\\AbstractGateway\:\:getAliasedColumns\(\) has parameter \$columns with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -28608,30 +28524,6 @@ parameters:
count: 1
path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:testCopyContentCopiesFieldRelations\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:testCreateContentRelationsProcessedCorrect\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:testSubtreeCopyContentCopiesFieldRelations\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:testUpdateContentRelationsProcessedCorrect\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#'
identifier: missingType.return
Expand Down Expand Up @@ -28686,30 +28578,6 @@ parameters:
count: 1
path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:testCopyContentCopiesFieldRelations\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:testCreateContentRelationsProcessedCorrect\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:testSubtreeCopyContentCopiesFieldRelations\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:testUpdateContentRelationsProcessedCorrect\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php

-
message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertFindResult\(\) has no return type specified\.$#'
identifier: missingType.return
Expand Down Expand Up @@ -47028,36 +46896,6 @@ parameters:
count: 1
path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php

-
message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceLoggerTest\:\:testGetCallValues\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/lib/Persistence/Cache/PersistenceLoggerTest.php

-
message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceLoggerTest\:\:testGetCalls\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/lib/Persistence/Cache/PersistenceLoggerTest.php

-
message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceLoggerTest\:\:testGetName\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/lib/Persistence/Cache/PersistenceLoggerTest.php

-
message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceLoggerTest\:\:testLogCall\(\) has no return type specified\.$#'
identifier: missingType.return
count: 1
path: tests/lib/Persistence/Cache/PersistenceLoggerTest.php

-
message: '#^Result of method Ibexa\\Core\\Persistence\\Cache\\PersistenceLogger\:\:logCall\(\) \(void\) is used\.$#'
identifier: method.void
count: 1
path: tests/lib/Persistence/Cache/PersistenceLoggerTest.php

-
message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
Expand Down Expand Up @@ -60105,7 +59943,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Language\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/Content/LanguageTest.php

-
Expand Down Expand Up @@ -60141,7 +59979,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Location\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/Content/LocationTest.php

-
Expand All @@ -60159,7 +59997,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/Content/SectionTest.php

-
Expand Down Expand Up @@ -60195,7 +60033,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\TrashItem\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/Content/TrashItemTest.php

-
Expand Down Expand Up @@ -60279,7 +60117,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroup\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php

-
Expand Down Expand Up @@ -60345,7 +60183,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\ObjectState\\ObjectState\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php

-
Expand Down Expand Up @@ -60411,7 +60249,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\User\\Policy\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/User/PolicyTest.php

-
Expand Down Expand Up @@ -60453,7 +60291,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\User\\Role\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/User/RoleTest.php

-
Expand Down Expand Up @@ -60495,7 +60333,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\User\\UserGroup\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/User/UserGroupTest.php

-
Expand Down Expand Up @@ -60549,7 +60387,7 @@ parameters:
-
message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\User\\User\:\:\$notDefined\.$#'
identifier: property.notFound
count: 2
count: 1
path: tests/lib/Repository/Values/User/UserTest.php

-
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ private function logTooEarlyLoadedListIfNeeded($paramName)
// Lookup trace to find last service being loaded as possible blame for eager loading
// Abort if one of the earlier services is detected to be "safe", aka updatable
foreach (debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 35) as $t) {
if (!isset($t['function']) || $t['function'] === 'getParameter' || $t['function'] === __FUNCTION__) {
if ($t['function'] === 'getParameter' || $t['function'] === __FUNCTION__) {
continue;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ class CreateStruct extends ValueObject
* This is allowed to be set to true, this will mean this should become main location
* (@todo Find a better way to deal with being able to create the main location)
*
* @var mixed|true
* @var int|true
*/
public $mainLocationId = true;

Expand Down
4 changes: 2 additions & 2 deletions src/lib/FieldType/Author/Type.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ class Type extends FieldType implements TranslationContainerInterface
* Flag which stands for setting Author FieldType empty by default.
* It is used in a content type edit view.
*/
public const DEFAULT_VALUE_EMPTY = 0;
public const int DEFAULT_VALUE_EMPTY = 0;

/**
* Flag which stands for prefilling Author FieldType with current user by default.
* It is used in a content type edit view.
*/
public const DEFAULT_CURRENT_USER = 1;
public const int DEFAULT_CURRENT_USER = 1;

protected $settingsSchema = [
'defaultAuthor' => [
Expand Down
Loading
Loading