From 9f43f107fb969391416054a8c52d845624b10833 Mon Sep 17 00:00:00 2001 From: Robert Fletcher Date: Sat, 27 Feb 2021 10:52:02 -0800 Subject: [PATCH] fix ActiveRecord deprecation warning ActiveRecord no longer wants us to pass SQL fragments to `order`. This instead makes use of the underlying framework Arel to generate the query. --- app/repositories/group_repository.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/repositories/group_repository.rb b/app/repositories/group_repository.rb index 61f30a914..b827dd199 100644 --- a/app/repositories/group_repository.rb +++ b/app/repositories/group_repository.rb @@ -2,6 +2,6 @@ class GroupRepository def self.list - Group.order("LOWER(name)") + Group.order(Group.arel_table[:name].lower) end end