Skip to content

Commit 614c35b

Browse files
AC-700 Fixed static tests failure
1 parent 45aee4e commit 614c35b

File tree

1 file changed

+7
-1
lines changed
  • app/code/Magento/Elasticsearch/SearchAdapter/Query/Builder

1 file changed

+7
-1
lines changed

app/code/Magento/Elasticsearch/SearchAdapter/Query/Builder/Sort.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,9 @@ public function __construct(
7474
*
7575
* @param RequestInterface $request
7676
* @return array
77+
*
78+
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
79+
* @SuppressWarnings(PHPMD.NPathComplexity)
7780
*/
7881
public function getSort(RequestInterface $request)
7982
{
@@ -94,7 +97,10 @@ public function getSort(RequestInterface $request)
9497
if (isset($this->map[$fieldName])) {
9598
$fieldName = $this->map[$fieldName];
9699
}
97-
if ($attribute->isSortable() && !$attribute->isComplexType() && !($attribute->isFloatType() || $attribute->isIntegerType())) {
100+
if ($attribute->isSortable() &&
101+
!$attribute->isComplexType() &&
102+
!($attribute->isFloatType() || $attribute->isIntegerType())
103+
) {
98104
$suffix = $this->fieldNameResolver->getFieldName(
99105
$attribute,
100106
['type' => FieldMapperInterface::TYPE_SORT]

0 commit comments

Comments
 (0)