Sha256: 4a98e9a86e51fab1116ffce886991bf395abdc28ebffeb49e9ab91e29bcf4783

Contents?: true

Size: 297 Bytes

Versions: 12

Compression:

Stored size: 297 Bytes

Contents

class User < Sequel::Model
  include DoorkeeperSequel::SequelCompat

  class << self
    def authenticate!(name, password)
      User.where(name: name, password: password).first
    end

    def create!(values = {}, &block)
      new(values, &block).save(raise_on_failure: true)
    end
  end
end

Version data entries

12 entries across 6 versions & 1 rubygems

Version Path
doorkeeper-sequel-2.4.0 spec/stubs/models/user.rb
doorkeeper-sequel-2.4.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-2.3.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-2.3.0 spec/stubs/models/user.rb
doorkeeper-sequel-2.2.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-2.2.0 spec/stubs/models/user.rb
doorkeeper-sequel-2.1.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-2.1.0 spec/stubs/models/user.rb
doorkeeper-sequel-2.0.0 spec/stubs/models/user.rb
doorkeeper-sequel-2.0.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-1.5.0 spec/dummy/app/models/user.rb
doorkeeper-sequel-1.5.0 spec/stubs/models/user.rb