smithycms-auth 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/smithy/user_sessions_controller.rb +5 -5
- data/config/routes.rb +2 -2
- data/lib/smithy/auth/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bb9fa1626d495474cbd81a07679d7b03e72b05da
|
4
|
+
data.tar.gz: 7f244607a1a51e629807bf56b9bed816b9849f8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19d96efc3c6b1f802e63a9daca67dd74a329d8aad8bbdfce972eb00478ded0e7aeed0582b1805df4261f8abdeafe1966251ac6308535ccdcdef97b120c24b9c4
|
7
|
+
data.tar.gz: 4ad8d4bcd85bb6435eb64f3b54accc13b8df25f49a3aba9490dd7fa523921c002e41f9af7c8943abe1edb066b69453692ded772da1f56858775c6d63633cbe83
|
@@ -27,11 +27,11 @@ module Smithy
|
|
27
27
|
Smithy.log :debug, "[Auth] session[:user_id]: #{session[:user_id].inspect}"
|
28
28
|
redirect_to root_url, :notice => "Logged out!"
|
29
29
|
end
|
30
|
-
end
|
31
30
|
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
31
|
+
private
|
32
|
+
def filtered_params
|
33
|
+
params.fetch(:login, {}).permit( :email, :password )
|
34
|
+
end
|
36
35
|
|
36
|
+
end
|
37
37
|
end
|
data/config/routes.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Smithy::Engine.routes.prepend do
|
2
2
|
scope '/smithy' do
|
3
|
-
get '/login' => 'user_sessions#new', :as => :login
|
4
|
-
delete '/logout' => 'user_sessions#destroy', :as => :logout
|
3
|
+
get '/login' => 'user_sessions#new', :as => :login unless has_named_route?(:login)
|
4
|
+
delete '/logout' => 'user_sessions#destroy', :as => :logout unless has_named_route?(:logout)
|
5
5
|
resource :user_session, :only => [:new, :create, :destroy]
|
6
6
|
resources :users
|
7
7
|
end
|
data/lib/smithy/auth/version.rb
CHANGED