app/controllers/application_controller.rb
# todo: logout in application controller is overwritten by logout in util controller. temporary using session_logout in util controller
#
logout in application controller is overwritten by logout in util controller. temporary using session_logout in util controller
logout in application controller is overwritten by logout in util controller . temporary using session_logout in util controller
def logout (provider=nil)
    if !provider
      session.delete(:user_ids)
      session.delete(:tokens)
      session.delete(:expires_at)
      @users = []
      add_dummy_user
      return
    end
    user_ids_tmp = get_session_value(:user_ids)
    user_ids_tmp = user_ids_tmp.delete_if { |user_id| user_id.split('/').last == provider}
    set_session_value(:user_ids, user_ids_tmp)
    delete_session_array_value(:tokens, provider)
    delete_session_array_value(:expires_at, provider)
    @users.delete_if { |user| user.provider == provider }
    add_dummy_user if @users.size == 0
  end
def logout ( provider = nil ) if ! provider session . delete ( :user_ids ) session . delete ( :tokens ) session . delete ( :expires_at ) @users = [ ] add_dummy_user return end user_ids_tmp = get_session_value ( :user_ids ) user_ids_tmp = user_ids_tmp . delete_if { | user_id | user_id . split ( '/' ) . last == provider } set_session_value ( :user_ids , user_ids_tmp ) delete_session_array_value ( :tokens , provider ) delete_session_array_value ( :expires_at , provider ) @users . delete_if { | user | user . provider == provider } add_dummy_user if @users . size == 0 end
todo: logout in application controller is overwritten by logout in util controller.
todo : logout in application controller is overwritten by logout in util controller .
provider
<not_specific>