From 697bd45420a35308cfcc71db5391ed42eb5e8886 Mon Sep 17 00:00:00 2001 From: Shyam Sunder Date: Thu, 24 Sep 2020 22:50:28 -0400 Subject: [PATCH] server/tag-categories: sort responses by order --- server/szurubooru/func/tag_categories.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/szurubooru/func/tag_categories.py b/server/szurubooru/func/tag_categories.py index 16962d9..d2c6021 100644 --- a/server/szurubooru/func/tag_categories.py +++ b/server/szurubooru/func/tag_categories.py @@ -152,7 +152,7 @@ def get_all_category_names() -> List[str]: def get_all_categories() -> List[model.TagCategory]: return ( db.session.query(model.TagCategory) - .order_by(model.TagCategory.name.asc()) + .order_by(model.TagCategory.order.asc(), model.TagCategory.name.asc()) .all() )