server/search: fix sort:random
This commit is contained in:
parent
fa60b42f65
commit
6d26b5c37a
1 changed files with 1 additions and 1 deletions
|
@ -10,7 +10,7 @@ def _format_dict_keys(source):
|
||||||
|
|
||||||
def _get_order(order, default_order):
|
def _get_order(order, default_order):
|
||||||
if order == tokens.SortToken.SORT_DEFAULT:
|
if order == tokens.SortToken.SORT_DEFAULT:
|
||||||
return default_order
|
return default_order or tokens.SortToken.SORT_ASC
|
||||||
if order == tokens.SortToken.SORT_NEGATED_DEFAULT:
|
if order == tokens.SortToken.SORT_NEGATED_DEFAULT:
|
||||||
if default_order == tokens.SortToken.SORT_ASC:
|
if default_order == tokens.SortToken.SORT_ASC:
|
||||||
return tokens.SortToken.SORT_DESC
|
return tokens.SortToken.SORT_DESC
|
||||||
|
|
Loading…
Reference in a new issue