Sha256: 16628915773b25462ddbadb33e49ae9c99e6ceb72441e105846aa0430184ee67

Contents?: true

Size: 382 Bytes

Versions: 7

Compression:

Stored size: 382 Bytes

Contents

class HomeController < ApplicationController
  def index; end

  def sign_in
    session[:user_id] = if Rails.env.development?
                          User.first || User.create!(name: 'Joe', password: 'sekret')
                        else
                          User.first
                        end
    redirect_to '/'
  end

  def callback
    render plain: 'ok'
  end
end

Version data entries

7 entries across 7 versions & 3 rubygems

Version Path
doorkeeper-5.0.3 spec/dummy/app/controllers/home_controller.rb
doorkeeper-5.1.0.rc2 spec/dummy/app/controllers/home_controller.rb
doorkeeper-5.1.0.rc1 spec/dummy/app/controllers/home_controller.rb
doorkeeper-5.0.2 spec/dummy/app/controllers/home_controller.rb
doorkeeper-mongodb-5.0.0 spec/dummy/app/controllers/home_controller.rb
doorkeeper-5.0.1 spec/dummy/app/controllers/home_controller.rb
doorkeeper-sequel-2.0.0 spec/dummy/app/controllers/home_controller.rb