aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/lib/active_model/attribute_methods.rb
diff options
context:
space:
mode:
authorSam Pohlenz <sam@sampohlenz.com>2009-10-07 09:06:54 -0500
committerJoshua Peek <josh@joshpeek.com>2009-10-07 09:07:39 -0500
commit4df96338ede62da8ae8c188de5454b4b6b186ff8 (patch)
treeae9fe8297d28d0a72750db082ce629c80e67d74d /activemodel/lib/active_model/attribute_methods.rb
parentf8e91bda9c171dd0c31dbea95ba4e9ced4ee2547 (diff)
downloadrails-4df96338ede62da8ae8c188de5454b4b6b186ff8.tar.gz
rails-4df96338ede62da8ae8c188de5454b4b6b186ff8.tar.bz2
rails-4df96338ede62da8ae8c188de5454b4b6b186ff8.zip
Fixed behavior of attribute_methods_generated? [#3220 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
Diffstat (limited to 'activemodel/lib/active_model/attribute_methods.rb')
-rw-r--r--activemodel/lib/active_model/attribute_methods.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activemodel/lib/active_model/attribute_methods.rb b/activemodel/lib/active_model/attribute_methods.rb
index 26ee9c4315..977a101277 100644
--- a/activemodel/lib/active_model/attribute_methods.rb
+++ b/activemodel/lib/active_model/attribute_methods.rb
@@ -165,6 +165,7 @@ module ActiveModel
end
end
end
+ @attribute_methods_generated = true
end
def undefine_attribute_methods
@@ -176,7 +177,6 @@ module ActiveModel
def generated_attribute_methods #:nodoc:
@generated_attribute_methods ||= begin
- @attribute_methods_generated = true
mod = Module.new
include mod
mod