forked from External/greenlight
committed by
Jesus Federico
parent
9dd30138ba
commit
ee26036105
@ -18,14 +18,21 @@
|
||||
|
||||
class ErrorsController < ApplicationController
|
||||
def not_found
|
||||
render status: 404, formats: :html
|
||||
render "greenlight_error", status: 404, formats: :html
|
||||
end
|
||||
|
||||
def internal_error
|
||||
render status: 500, formats: :html
|
||||
render "errors/greenlight_error", status: 500, formats: :html,
|
||||
locals: {
|
||||
status_code: 500,
|
||||
message: I18n.t("errors.internal.message"),
|
||||
help: I18n.t("errors.internal.help"),
|
||||
display_back: true
|
||||
}
|
||||
end
|
||||
|
||||
def unauthorized
|
||||
render status: 401, formats: :html
|
||||
render "errors/greenlight_error", status: 401, formats: :html, locals: { status_code: 401,
|
||||
message: I18n.t("errors.unauthorized.message"), help: I18n.t("errors.unauthorized.help"), display_back: true }
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user