Sha256: b87dac714c0452af58b52c5dbe02e3c9d79a3ad618e0617351b25b46fef4c4c9
Contents?: true
Size: 761 Bytes
Versions: 14
Compression:
Stored size: 761 Bytes
Contents
module Refinery class SessionsController < Devise::SessionsController helper Refinery::Core::Engine.helpers layout 'refinery/layouts/login' before_filter :clear_unauthenticated_flash, :only => [:new] def create super rescue ::BCrypt::Errors::InvalidSalt, ::BCrypt::Errors::InvalidHash flash[:error] = t('password_encryption', :scope => 'refinery.users.forgot') redirect_to refinery.new_refinery_user_password_path end protected # We don't like this alert. def clear_unauthenticated_flash if flash.keys.include?(:alert) and flash.any?{|k, v| ['unauthenticated', t('unauthenticated', :scope => 'devise.failure')].include?(v) } flash.delete(:alert) end end end end
Version data entries
14 entries across 14 versions & 1 rubygems