For orderby=random, don't add -asc -desc to the URL.

This commit is contained in:
voussoir 2019-08-23 13:25:21 -07:00
parent a7d93b7223
commit 45d8f0df1a

View file

@ -521,9 +521,16 @@ function submit_search()
{ {
var row = orderby_rows[index]; var row = orderby_rows[index];
var column = row.children[0].value; var column = row.children[0].value;
if (column == "random")
{
orderby_params.push(column);
}
else
{
var sorter = row.children[1].value; var sorter = row.children[1].value;
orderby_params.push(column + "-" + sorter); orderby_params.push(column + "-" + sorter);
} }
}
orderby_params = orderby_params.join(","); orderby_params = orderby_params.join(",");
if (orderby_params && orderby_params != "created-desc") if (orderby_params && orderby_params != "created-desc")
{ {