You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was attempting to use a field with name "display"; example:
class TestHash < ActiveHash::Base
field :display, default: true
add
add display: false
end
However, ActiveHash defines method only if an existing instance method does not already exist, and Rails adds this method to either Object or Kernel. Ex:
While I totally understand the rationale here, I think it would be really helpful if you could spit out a warning or error if we attempt to define a method that is already defined. The result of the above issue was that most of my test suite failed and I had countless lines outputting the class information for individual ActiveHash records.
The text was updated successfully, but these errors were encountered:
I was attempting to use a field with name "display"; example:
However, ActiveHash defines method only if an existing instance method does not already exist, and Rails adds this method to either Object or Kernel. Ex:
While I totally understand the rationale here, I think it would be really helpful if you could spit out a warning or error if we attempt to define a method that is already defined. The result of the above issue was that most of my test suite failed and I had countless lines outputting the class information for individual ActiveHash records.
The text was updated successfully, but these errors were encountered: