Skip to content

Commit 7b3073b

Browse files
committed
Merge pull request activeadmin#71 from daniel-g/master
Do not split the sort
2 parents 3fa3b4b + 6658578 commit 7b3073b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/active_admin/mongoid/document.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,7 @@ def columns_hash
115115

116116
def reorder sorting
117117
return unscoped if sorting.blank?
118-
options = sorting.split(/ |\./)
119-
options.shift if options.count == 3
118+
options = sorting.split(' ')
120119
field, order = *options
121120
unscoped.order_by(field => order)
122121
end

0 commit comments

Comments
 (0)