Sha256: 22b7076762c626c5f203b81c9d42d4bf80a8a367b331f37e06624d5839b93dd2
Contents?: true
Size: 618 Bytes
Versions: 11
Compression:
Stored size: 618 Bytes
Contents
case DOORKEEPER_ORM.to_s when "active_record" class User < ActiveRecord::Base end when /mongoid/ class User include Mongoid::Document include Mongoid::Timestamps field :name, type: String field :password, type: String end when "mongo_mapper" class User include MongoMapper::Document timestamps! key :name, String key :password, String end end class User if ::Rails.version.to_i < 4 || defined?(::ProtectedAttributes) attr_accessible :name, :password end def self.authenticate!(name, password) User.where(name: name, password: password).first end end
Version data entries
11 entries across 11 versions & 1 rubygems