Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class HomeController < ApplicationController
- def index
- debugger
- if current_user
- if current_user.role?(:respondent)
- @questionnaires = Questionnaire.authorized_questionnaires(current_user)
- elsif current_user.role?(:delegate)
- redirect_to dashboard_delegate_path(current_user.id)
- end
- else
- @user_session = UserSession.new
- end
- end
- end
Add Comment
Please, Sign In to add comment