Skip to content

Commit

Permalink
PD-115 Fix PHPStan (#4)
Browse files Browse the repository at this point in the history
* PD-115 Fix PHPStan

* PD-105 Update composer dependencies.

* PD-105 Update composer description.

* PD-105 Removed unused autoload.

* PD-105 Require symfony/messenger 6.4
  • Loading branch information
martineiber authored Jan 29, 2024
1 parent c822045 commit 05877c8
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "pimcore/generic-data-index-bundle",
"license": "Pimcore Enterprise License (PEL)",
"type": "pimcore-bundle",
"description": "Pimcore xTemplate Bundlex",
"description": "Pimcore Generic data index Bundle",
"config": {
"discard-changes": true,
"sort-packages": true,
Expand All @@ -19,10 +19,11 @@
"require": {
"php": "~8.1.0 || ~8.2.0",
"pimcore/enterprise-subscription-tools": "^1.3",
"pimcore/pimcore": "^11.0",
"pimcore/pimcore": "^11.1",
"opensearch-project/opensearch-php": "^2.2.0",
"doctrine/orm": "^2.17.2",
"symfony/scheduler": "^6.3|^7.0"
"symfony/scheduler": "^6.4",
"symfony/messenger": "^6.4"
},
"require-dev": {
"roave/security-advisories": "dev-latest",
Expand All @@ -40,8 +41,7 @@
},
"autoload": {
"psr-4": {
"Pimcore\\Bundle\\GenericDataIndexBundle\\": "src/",
"Pimcore\\": "core-extension/Pimcore/"
"Pimcore\\Bundle\\GenericDataIndexBundle\\": "src/"
}
},
"autoload-dev": {
Expand Down
2 changes: 1 addition & 1 deletion src/Service/SearchIndex/OpenSearch/OpenSearchService.php
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ public function putMapping(array $params): array

public function countByAttributeValue(string $indexName, string $attribute, string $value): int
{
$this->openSearchClient->search([
$countResult = $this->openSearchClient->search([
'index' => $indexName,
'track_total_hits' => true,
'rest_total_hits_as_int' => true,
Expand Down
5 changes: 3 additions & 2 deletions src/Service/SearchIndex/OpenSearch/PathService.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public function __construct(
}

/**
* Directly update children paths in OpenSearch for assets as otherwise you might get strange results if you rename a folder in the portal engine frontend.
* Directly update children paths in OpenSearch for assets as otherwise you might get strange results
* if you rename a folder in the portal engine frontend.
*
* @throws Exception
*/
Expand Down Expand Up @@ -134,7 +135,7 @@ private function updatePath(string $indexName, string $currentPath, string $newP

private function countDocumentsByPath(string $indexName, string $path): int
{
$this->openSearchClient->search([
$countResult = $this->openSearchClient->search([
'index' => $indexName,
'track_total_hits' => true,
'rest_total_hits_as_int' => true,
Expand Down

0 comments on commit 05877c8

Please sign in to comment.