Sha256: cef0caea21f6a2e988805d335691b201240245b4cc7945990ce9eb3874238d05
Contents?: true
Size: 444 Bytes
Versions: 3
Compression:
Stored size: 444 Bytes
Contents
module SlashAdmin class ApplicationController < ActionController::Base protect_from_forgery with: :exception before_action :set_locale helper Rails.application.routes.url_helpers def current_ability @current_ability ||= SlashAdmin::AdminAbility.new(current_admin) end private def set_locale I18n.locale = http_accept_language.compatible_language_from(I18n.available_locales) end end end
Version data entries
3 entries across 3 versions & 1 rubygems