fix set attributes on set_parent (rails 3)