mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
822742164e
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@254 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
14 lines
No EOL
457 B
Ruby
14 lines
No EOL
457 B
Ruby
module ActionController #:nodoc:
|
|
module Session #:nodoc:
|
|
def self.append_features(base) #:nodoc:
|
|
super #:nodoc:
|
|
base.after_filter(:clear_persistant_model_associations)
|
|
end
|
|
|
|
private
|
|
def clear_persistant_model_associations #:doc:
|
|
session = @session.instance_variable_get("@data")
|
|
session.each { |key, obj| obj.clear_association_cache if obj.respond_to?(:clear_association_cache) } if session
|
|
end
|
|
end
|
|
end |