Skip to content

Commit

Permalink
fix sorting by position as default from 0
Browse files Browse the repository at this point in the history
  • Loading branch information
damonsson committed Sep 30, 2019
1 parent 5b2e27d commit f340c67
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public function retrieveData(array $requestData): array
$positionSortingProperty = $this->getPositionSortingProperty();

$orderBy = isset($requestData[self::ORDER_BY_INDEX]) ? $requestData[self::ORDER_BY_INDEX] : $positionSortingProperty;
$sort = isset($requestData[self::SORT_INDEX]) ? $requestData[self::SORT_INDEX] : self::SORT_DESC_INDEX;
$sort = isset($requestData[self::SORT_INDEX]) ? $requestData[self::SORT_INDEX] : self::SORT_ASC_INDEX;

$availableSorters = [$positionSortingProperty, $this->soldUnitsProperty, $this->createdAtProperty, $this->pricePropertyPrefix];
$availableSorting = [self::SORT_ASC_INDEX, self::SORT_DESC_INDEX];
Expand Down

0 comments on commit f340c67

Please sign in to comment.