From ab48435211505ebb29b35513dba995664c0f1915 Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Tue, 15 May 2012 15:27:46 -0300 Subject: [PATCH] Remove warning with shadowing variable --- lib/devise/controllers/helpers.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/devise/controllers/helpers.rb b/lib/devise/controllers/helpers.rb index abbccaeb..471ac258 100644 --- a/lib/devise/controllers/helpers.rb +++ b/lib/devise/controllers/helpers.rb @@ -88,8 +88,8 @@ module Devise # Return true if the given scope is signed in session. If no scope given, return # true if any scope is signed in. Does not run authentication hooks. def signed_in?(scope=nil) - [ scope || Devise.mappings.keys ].flatten.any? do |scope| - warden.authenticate?(:scope => scope) + [ scope || Devise.mappings.keys ].flatten.any? do |_scope| + warden.authenticate?(:scope => _scope) end end @@ -155,7 +155,7 @@ module Devise warden.raw_session.inspect warden.logout expire_devise_cached_variables! - + users.any? end