Skip to content
This repository has been archived by the owner on Apr 17, 2018. It is now read-only.

dm-is-versioned doesn't work with dm-timestamps #4

Open
solnic opened this issue May 17, 2011 · 3 comments
Open

dm-is-versioned doesn't work with dm-timestamps #4

solnic opened this issue May 17, 2011 · 3 comments
Labels

Comments

@solnic
Copy link
Contributor

solnic commented May 17, 2011

Due to changes in the way dm-timestamps updates the timestamps, dm-is-versioned will no longer trigger the saving of new versions when updated_at changes. This is because dm-timestamps bypasses the property accessor methods dm-is-versioned uses to determine changes and instead uses property#set.

See the attached script for the effect this has.


Created by Jonathan Stott (namelessjon) - 2010-01-20 13:46:29 UTC

Original Lighthouse ticket: http://datamapper.lighthouseapp.com/projects/20609/tickets/1184

@solnic
Copy link
Contributor Author

solnic commented May 17, 2011

It’s no longer an issue.

by Piotr Solnica (solnic)

@solnic
Copy link
Contributor Author

solnic commented May 17, 2011

hmm actually it still doesn’t work even though dm-timestamps uses #attribute_set now

by Piotr Solnica (solnic)

@solnic
Copy link
Contributor Author

solnic commented May 17, 2011

You do have a pull request sitting in the repository that actually fixes this:

#3

The original bug is related to dm-is-versioned hooking #{attribute}= and keeping track of changes itself instead of using datamappers internal tracking of dirty attributes. So it never sees change done by attribute_set.

Sorry for the late mentioning in the bugtracker.

Regards,
Florian Gilcher

by Florian Gilcher

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant