Looking for feedback on minor Dirty tracking enhancement

Linky: http://rails.lighthouseapp.com/projects/8994/tickets/798

It boils down to making this work:

phrase = "shiver me timbers" pirate = Pirate.create!(:catchphrase => phrase) pirate.catchphrase = "*hic*" assert pirate.changed? pirate.catchphrase = phrase assert !pirate.changed?

Thanks    -Tom

What's the real world use case?

Damian Janowski wrote:

Yeah, I understand the idea. I'm just asking what the use case is in real world code because I can't think of any.

Although it looks good in script/console, maybe the overhead is not worth it...

one use case would be merging updates from two different sources

1. 1st set of attribute values (from source a) modifies a value

2. 2nd set of attribute values (from source b - which your application decides has precedence) restores one or more of the original values

3. save update(s)

+1 for a nice patch... good understanding of the mechanism