File tree Expand file tree Collapse file tree 1 file changed +8
-12
lines changed
Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Original file line number Diff line number Diff line change @@ -58,13 +58,11 @@ def self.prepare_backend
5858 else
5959 redirect_to spree . admin_unauthorized_path
6060 end
61- else
61+ elsif Spree :: Auth :: Engine . redirect_back_on_unauthorized?
6262
63- if Spree ::Auth ::Engine . redirect_back_on_unauthorized?
64- redirect_back ( fallback_location : spree . admin_login_path )
65- else
66- redirect_to spree . admin_login_path
67- end
63+ redirect_back ( fallback_location : spree . admin_login_path )
64+ else
65+ redirect_to spree . admin_login_path
6866 end
6967 end
7068 end
@@ -79,13 +77,11 @@ def self.prepare_frontend
7977 else
8078 redirect_to spree . unauthorized_path
8179 end
82- else
80+ elsif Spree :: Auth :: Engine . redirect_back_on_unauthorized?
8381
84- if Spree ::Auth ::Engine . redirect_back_on_unauthorized?
85- redirect_back ( fallback_location : spree . login_path )
86- else
87- redirect_to spree . login_path
88- end
82+ redirect_back ( fallback_location : spree . login_path )
83+ else
84+ redirect_to spree . login_path
8985 end
9086 end
9187 end
You can’t perform that action at this time.
0 commit comments