-
-
Notifications
You must be signed in to change notification settings - Fork 466
Expand file tree
/
Copy pathroutes.rb
More file actions
28 lines (24 loc) · 831 Bytes
/
routes.rb
File metadata and controls
28 lines (24 loc) · 831 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
if Clearance.configuration.routes_enabled?
Rails.application.routes.draw do
resources :passwords,
controller: "clearance/passwords",
only: [:create, :new]
resource :session,
controller: "clearance/sessions",
only: [:create]
resources :users,
controller: "clearance/users",
only: Clearance.configuration.user_actions do
if Clearance.configuration.allow_password_reset?
resource :password,
controller: "clearance/passwords",
only: [:edit, :update]
end
end
get "/sign_in" => "clearance/sessions#new", :as => "sign_in"
delete "/sign_out" => "clearance/sessions#destroy", :as => "sign_out"
if Clearance.configuration.allow_sign_up?
get "/sign_up" => "clearance/users#new", :as => "sign_up"
end
end
end