Permalink
Browse files

Uncache find overload

  • Loading branch information...
1 parent 8142176 commit 77826aa3048799d31d4b7f96c8e91493bd320865 @davidkennedy-examtime davidkennedy-examtime committed Feb 9, 2012
Showing with 6 additions and 4 deletions.
  1. +6 −4 lib/acts_as_network.rb
View
@@ -82,10 +82,12 @@ def initialize(*sets)
# union.find(:first, :conditions => ["name = ?", "George"])
#
def find(*args)
- case args.first
- when :first then find_initial(:find, *args)
- when :all then find_all(:find, *args)
- else find_from_ids(:find, *args)
+ ActiveRecord::Base.connection.uncached do
+ case args.first
+ when :first then find_initial(:find, *args)
+ when :all then find_all(:find, *args)
+ else find_from_ids(:find, *args)
+ end
end
end

0 comments on commit 77826aa

Please sign in to comment.