#964 ✓resolved
siplux

dm-tags doesn't update tags when set through attributes

Reported by siplux | July 9th, 2009 @ 05:33 PM | in 0.10.0

If you attempt to update the tag_list via a hash of attributes rather than a method call, it will just delete existing tags without updating them. However, it will correctly set the frozen_tag_list even though it deletes existing tags.

Broken

IRB:

>> u = User.first
>> u.profession_list

=> ["Government"]

 


>> u.attributes(:profession_list => "Education") >> u.save

=> true




>> u = User.first >> u.profession_list

=> []




>> u.frozen_profession_list

=> "Education"




Works

IRB:

>> u = User.first
>> u.profession_list = "Education"

=> "Education"

 


>> u.save

=> true




>> u.profession_list

=> ["Education"]




Comments and changes to this ticket

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.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Pages