aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorGiteabot <teabot@gitea.io>2024-01-23 15:00:52 +0800
committerGitHub <noreply@github.com>2024-01-23 08:00:52 +0100
commitb508813fe48fde6eff4ea33713305ef6b81e2f4e (patch)
tree445b2726be4b016c1c1b72ec74c371bb38d5a17f /modules
parentfd1edb9d9d3ca701c6568de75d6ecfeccda88e51 (diff)
downloadgitea-b508813fe48fde6eff4ea33713305ef6b81e2f4e.tar.gz
gitea-b508813fe48fde6eff4ea33713305ef6b81e2f4e.zip
Fix sort bug on repository issues list (#28897) (#28901)
Backport #28897 by @lunny Fix #28896 Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'modules')
-rw-r--r--modules/indexer/issues/db/options.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/indexer/issues/db/options.go b/modules/indexer/issues/db/options.go
index 4d3fa44ca6..158b7397e2 100644
--- a/modules/indexer/issues/db/options.go
+++ b/modules/indexer/issues/db/options.go
@@ -38,7 +38,7 @@ func ToDBOptions(ctx context.Context, options *internal.SearchOptions) (*issue_m
sortType = "leastupdate"
case internal.SortByCommentsAsc:
sortType = "leastcomment"
- case internal.SortByDeadlineAsc:
+ case internal.SortByDeadlineDesc:
sortType = "farduedate"
case internal.SortByCreatedDesc:
sortType = "newest"
@@ -46,7 +46,7 @@ func ToDBOptions(ctx context.Context, options *internal.SearchOptions) (*issue_m
sortType = "recentupdate"
case internal.SortByCommentsDesc:
sortType = "mostcomment"
- case internal.SortByDeadlineDesc:
+ case internal.SortByDeadlineAsc:
sortType = "nearduedate"
default:
sortType = "newest"