
Hooks run twice when a newly created resource is saved, but not if it is refetched from the db
Reported by Nathan | July 17th, 2009 @ 03:59 PM | in 0.10.0
Yeah, so #save seems to run after/before :save callbacks twice if the Resource instance is newly created and has a has 1.
If you refetch (Model.first), then #save doesn't exhibit this same behavior.
See standalone example: http://gist.github.com/149224
Comments and changes to this ticket
-
Dan Kubb (dkubb) July 22nd, 2009 @ 03:51 PM
- State changed from new to unconfirmed
- Milestone cleared.
-
Martin Gamsjaeger (snusnu) October 3rd, 2009 @ 12:36 PM
- Milestone set to 0.10.1
- State changed from unconfirmed to resolved
Seems to work on latest master. Here's what I get http://pastie.org/640589
-
Martin Gamsjaeger (snusnu) October 3rd, 2009 @ 12:37 PM
- Milestone changed from 0.10.1 to 0.10.0
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 »