
Redefining hook on STI subclass doesn't work
Reported by Marcin Kulik | May 14th, 2010 @ 12:16 PM | in 1.0.0
DM crashes when you try to add hook to STI subclass (a hook which was already added to superclass).
Look here for example:
http://gist.github.com/401379
When you run this code you'll get:
dm-core/model/hook.rb:57: undefined method []' for
nil:NilClass (NoMethodError)
It's broken on current master, on 0.10.2 seems to work correctly.
Comments and changes to this ticket
-
Dan Kubb (dkubb) May 29th, 2010 @ 01:54 AM
- Milestone set to 1.0.0
- State changed from new to confirmed
I can confirm this behaviour with edge dm-core.
-
Dan Kubb (dkubb) May 29th, 2010 @ 01:54 AM
- State changed from confirmed to accepted
-
Dan Kubb (dkubb) May 29th, 2010 @ 02:01 AM
- State changed from accepted to resolved
(from [9baf927f726d23caee74edcb8e422c5946846e89]) Fixed bug with hooks applied to subclasses
- Improved specs for resource hooks
- Added specs for inherited after hooks
- Changed inherited hooks to be based on instance method
[#1271 state:resolved] http://github.com/datamapper/dm-core/commit/9baf927f726d23caee74edc...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
People watching this ticket
Referenced by
-
1271 Redefining hook on STI subclass doesn't work [#1271 state:resolved] http://github.com/datamapper/dm-c...