Skip to content
Snippets Groups Projects
Commit 3a9afa28 authored by Cam Saül's avatar Cam Saül Committed by GitHub
Browse files

Merge pull request #4073 from metabase/sort-segments-when-returning

Sort segments by name in GET /api/segment
parents f17d3e99 dae31520
No related branches found
No related tags found
No related merge requests found
......@@ -33,7 +33,7 @@
(defendpoint GET "/"
"Fetch *all* `Segments`."
[]
(filter models/can-read? (-> (db/select Segment, :is_active true)
(filter models/can-read? (-> (db/select Segment, :is_active true, {:order-by [[:%lower.name :asc]]})
(hydrate :creator))))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment