Merge branch '1675-preactivation'
[arvados.git] / apps / workbench / app / controllers / sessions_controller.rb
1 class SessionsController < ApplicationController
2   skip_around_filter :thread_with_api_token, :only => [:destroy, :index]
3   skip_before_filter :find_object_by_uuid, :only => [:destroy, :index]
4   def destroy
5     session.clear
6     redirect_to $arvados_api_client.arvados_logout_url(return_to: logged_out_url)
7   end
8   def index
9     redirect_to root_url if session[:arvados_api_token]
10   end
11 end