If you want to switch the boolean value:
u.<attribute>.toggle!
If you want to set a boolean:
u.<attribute> = [true|false]
If you want to immediately update the boolean value:
u.update_column(:<attribute>, [true|false]) # Doesn't update timestamps or call callbacks u.update_attribute(:<attribute>, [true|false])
pdobb source share