I personally find confusing the difference between `update_attributes` and
`update_attribute`. Intuitively, it seems that it is only a matter of
plural/singular (the first one changes more than one attribute through a
Hash argument and the second one changes only one through a column and a
value argument). Therefore, the implicitly validation skipping is something
that I (and when I say I, I'm saying IMHO) dislike.

I'm +1 for the change :).

On Thu, Jun 14, 2012 at 10:15 AM, Simon de Boer <[email protected]> wrote:

> FWIW: This subtle difference disturbed me so much that I just alias
> update_attribute to update_attribute*s*.
>
> I'm very pleased to learn about update_column for the strange edge case
> where you need it direct.
>
> +1 for deprecation and emphasizing update_column.
>
>
> On Thursday, 14 June 2012 08:31:22 UTC-4, MikeGehard wrote:
>>
>> Thanks for the history lesson Xavier.
>>
>> Knowing that history, I like Steve's idea of deprecating update_attribute
>> and advertising update_column as the fast way to update a single column and
>> update_attributes as the way to run through the whole update "stack".
>>
>> On Thursday, June 14, 2012 5:39:38 AM UTC-6, Steve Klabnik wrote:
>>>
>>> I don't think that the 's' is a big enough change to make it
>>> noticeable. I like update_column, maybe a bang method would make sense
>>> too. But I'd expect them to both run validations.
>>>
>>> Maybe deprecating one is a good idea.
>>>
>>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby on Rails: Core" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/rubyonrails-core/-/tvA_NDIEJ5QJ.
>
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/rubyonrails-core?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-core?hl=en.

Reply via email to