Class: Devise::YauthSettingsController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/devise/yauth_settings_controller.rb

Instance Method Summary collapse

Instance Method Details

#statusObject



9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'app/controllers/devise/yauth_settings_controller.rb', line 9

def status
  if params[:account_id]
    a = Account.where(:yauth_account_id => params[:account_id]).first
    if a.respond_to?(:status_parameters)
      render :json => to_json_api(a.status_parameters)
    else
      render :json => to_json_api(:ok)
    end
  else
    a = Account.first
    u = User.first
    render :text => :ok
  end
end

#widgetObject



5
6
7
# File 'app/controllers/devise/yauth_settings_controller.rb', line 5

def widget
  redirect_to "http://#{.yauth_host}/api/auth/widget.json?continue=#{params[:continue]}&callback=#{params[:callback]}"
end