Display launcher errors in Greenlight (#742)

This commit is contained in:
shawn-higgins1 2019-08-15 10:17:32 -04:00 committed by Jesus Federico
parent 4d14c5fc23
commit de81223413
2 changed files with 6 additions and 1 deletions

View File

@ -57,7 +57,11 @@ class SessionsController < ApplicationController
# POST /auth/failure
def omniauth_fail
redirect_to root_path, alert: I18n.t(params[:message], default: I18n.t("omniauth_error"))
if params[:message].nil?
redirect_to root_path, alert: I18n.t("omniauth_error")
else
redirect_to root_path, alert: I18n.t("omniauth_specific_error", error: params["message"])
end
end
# GET /auth/ldap

View File

@ -333,6 +333,7 @@ en:
name_update_success: Room name successfully changed!
no_user_email_exists: There is no existing user with the email specified. Please make sure you typed it correctly.
omniauth_error: An error occured while authenticating with omniauth. Please try again or contact an administrator!
omniauth_specific_error: "%{error} occured while authenticating with omniauth. Please try again or contact an administrator!"
pagy:
nav:
prev: "&lsaquo; Prev"