Skip to content

Commit

Permalink
Fix filterSelector for PageSizeBehavior class
Browse files Browse the repository at this point in the history
  • Loading branch information
sanchezzzhak authored Oct 11, 2023
1 parent eeaed1e commit 977a363
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/behaviors/PageSizeBehavior.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ public function run(){
$owner = $this->owner;

// set selector filters
$selector = ' #'.$owner->id . ' select[name="per-page"]';
$filters = explode(',', $owner->filterSelector);
$selector = sprintf(' #%s select[name="per-page"]', $owner->id);
$filters = explode(',', (string)$owner->filterSelector);
if (!in_array($selector, $filters)) {
$filters[] = $selector;
$owner->filterSelector = implode(',', array_filter($filters, function ($val) {
Expand All @@ -91,4 +91,4 @@ public function renderPageSize()
}


}
}

0 comments on commit 977a363

Please sign in to comment.