Skip to content

Commit

Permalink
Revert my previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
wilsonge committed Dec 2, 2020
1 parent efab02d commit 411585f
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions libraries/src/Form/Field/TagField.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,13 @@ protected function getInput()
*/
protected function getOptions()
{
$published = $this->element['published'] ?: array(0, 1);
$app = Factory::getApplication();
$language = null;
$options = [];
$published = $this->element['published'] ?: array(0, 1);
$app = Factory::getApplication();
$language = null;
$options = [];

// This limit is only used with isRemoteSearch
$prefillLimit = 30;
$isRemoteSearch = $this->isRemoteSearch();

$db = Factory::getDbo();
Expand Down Expand Up @@ -198,8 +201,6 @@ protected function getOptions()
// Preload only active values and 30 most used tags or fill up
if ($isRemoteSearch)
{
$prefillLimit = 30;

// Load the most $prefillLimit used tags
$topQuery = $db->getQuery(true)
->select($db->quoteName('tag_id'))
Expand Down

0 comments on commit 411585f

Please sign in to comment.