mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Honor the order in the new finder
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1167 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
parent
624d5bb176
commit
9dd8d3d3e4
1 changed files with 1 additions and 0 deletions
|
@ -66,6 +66,7 @@ module ActiveRecord
|
|||
end
|
||||
else
|
||||
options[:conditions] = @finder_sql + (options[:conditions] ? " AND #{options[:conditions]}" : "")
|
||||
options[:order] = options[:order] ? "#{options[:order]}, #{@options[:order]}" : @options[:order]
|
||||
@association_class.find(args.size == 1 ? args.first : args, options)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue