Module Sequel::Plugins::BlacklistSecurity::InstanceMethods
In: lib/sequel/plugins/blacklist_security.rb

Methods

Classes and Modules

Class Sequel::Plugins::BlacklistSecurity::InstanceMethods::ExceptionList

Public Instance methods

Set all values using the entries in the hash, except for the keys given in except. You should probably use set_fields or set_only instead of this method, as blacklist approaches to security are a bad idea.

  artist.set_except({:name=>'Jim'}, :hometown)
  artist.name # => 'Jim'

[Source]

    # File lib/sequel/plugins/blacklist_security.rb, line 64
64:         def set_except(hash, *except)
65:           set_restricted(hash, ExceptionList.new(except.flatten))
66:         end

Update all values using the entries in the hash, except for the keys given in except. You should probably use update_fields or update_only instead of this method, as blacklist approaches to security are a bad idea.

  artist.update_except({:name=>'Jim'}, :hometown) # UPDATE artists SET name = 'Jim' WHERE (id = 1)

[Source]

    # File lib/sequel/plugins/blacklist_security.rb, line 73
73:         def update_except(hash, *except)
74:           update_restricted(hash, ExceptionList.new(except.flatten))
75:         end

[Validate]