trusty-cms 3.8.0 → 3.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +100 -92
  3. data/app/assets/images/admin/default_forgot_password.svg +1 -0
  4. data/app/assets/images/admin/default_reset_password.svg +1 -0
  5. data/app/assets/images/admin/default_safe_login.svg +1 -0
  6. data/app/assets/javascripts/admin.js +0 -1
  7. data/app/assets/javascripts/admin/modernizr.js +3 -409
  8. data/app/assets/stylesheets/admin/partials/_forms.scss +39 -0
  9. data/app/assets/stylesheets/admin/partials/_layout.scss +8 -0
  10. data/app/assets/stylesheets/admin/partials/_validations.scss +6 -13
  11. data/app/controllers/admin/assets_controller.rb +7 -0
  12. data/app/controllers/admin/preferences_controller.rb +1 -1
  13. data/app/controllers/admin/resource_controller.rb +6 -0
  14. data/app/controllers/admin/users_controller.rb +3 -2
  15. data/app/controllers/application_controller.rb +5 -7
  16. data/app/controllers/site_controller.rb +2 -1
  17. data/app/controllers/social_mailer_controller.rb +2 -1
  18. data/app/models/legacy_user.rb +6 -0
  19. data/app/models/user.rb +39 -68
  20. data/app/models/user_action_observer.rb +4 -2
  21. data/app/views/admin/configuration/show.html.haml +2 -7
  22. data/app/views/admin/layouts/_site_chooser.html.haml +1 -1
  23. data/app/views/admin/pages/_node.html.haml +2 -2
  24. data/app/views/admin/preferences/edit.html.haml +9 -14
  25. data/app/views/admin/users/_form.html.haml +8 -15
  26. data/app/views/admin/users/index.html.haml +0 -1
  27. data/app/views/devise/passwords/edit.html.haml +23 -0
  28. data/app/views/devise/passwords/new.html.haml +14 -0
  29. data/app/views/devise/sessions/new.html.haml +25 -0
  30. data/app/views/devise/shared/_links.html.haml +16 -0
  31. data/app/views/layouts/application.html.haml +1 -1
  32. data/config/application.rb +1 -0
  33. data/config/initializers/devise.rb +310 -0
  34. data/config/routes.rb +6 -10
  35. data/db/migrate/20200117141251_create_admin_users.rb +51 -0
  36. data/lib/generators/extension_controller/templates/controller.rb +1 -1
  37. data/lib/login_system.rb +40 -44
  38. data/lib/tasks/upgrade_to_devise.rake +22 -0
  39. data/lib/trusty_cms.rb +1 -1
  40. data/lib/trusty_cms/admin_ui.rb +3 -3
  41. data/lib/trusty_cms/engine.rb +2 -0
  42. data/lib/trusty_cms/setup.rb +0 -1
  43. data/trusty_cms.gemspec +1 -0
  44. data/vendor/extensions/clipped-extension/clipped_extension.rb +0 -2
  45. data/vendor/extensions/multi-site-extension/lib/multi_site/site_chooser_helper.rb +1 -1
  46. data/vendor/extensions/snippets-extension/snippets_extension.rb +0 -2
  47. metadata +27 -8
  48. data/app/assets/javascripts/admin/cookie.js +0 -80
  49. data/app/controllers/admin/password_resets_controller.rb +0 -31
  50. data/app/controllers/admin/welcome_controller.rb +0 -47
  51. data/app/views/admin/password_resets/edit.html.haml +0 -27
  52. data/app/views/admin/password_resets/new.html.haml +0 -12
  53. data/app/views/password_mailer/password_reset.html.haml +0 -8
@@ -1,26 +1,24 @@
1
1
  = form_for [:admin, @user], :html => {class: "user_form"} do |f|
2
- = hidden_field "user", "lock_version"
3
-
4
2
  = render :partial => 'avatar' unless @user.new_record?
5
3
 
6
4
  = render_region :form_top, :locals => {:f => f}
7
5
 
8
6
  - render_region :form, :locals => {:f => f} do |form|
9
- - form.edit_name do
7
+ - form.edit_first_name do
8
+ %p
9
+ = f.label :name, t('first_name')
10
+ = f.text_field :first_name, :class => "textbox", :size => 32, :maxlength => 100
11
+
12
+ - form.edit_last_name do
10
13
  %p
11
- = f.label :name, t('name')
12
- = f.text_field :name, :class => "textbox", :size => 32, :maxlength => 100
14
+ = f.label :name, t('last_name')
15
+ = f.text_field :last_name, :class => "textbox", :size => 32, :maxlength => 100
13
16
 
14
17
  - form.edit_email do
15
18
  %p
16
19
  = f.label :email, t('email_address') , :class => "optional"
17
20
  = f.text_field "email", :class => 'textbox', :size => 32, :maxlength => 255
18
21
 
19
- - form.edit_username do
20
- %p
21
- = f.label :login, t('username')
22
- = f.text_field "login", :class => "textbox", :size => 32, :maxlength => 40, :autocomplete => 'off'
23
-
24
22
  - form.edit_password do
25
23
  = render "password_fields", :f => f
26
24
 
@@ -32,11 +30,6 @@
32
30
  = f.check_box "designer", :class => "checkbox"
33
31
  = f.label :designer, t('designer'), :class => "checkbox"
34
32
 
35
- - form.edit_locale do
36
- %p
37
- = f.label :locale, t('language')
38
- = f.select "locale", available_locales_select
39
-
40
33
  - form.edit_notes do
41
34
  %p
42
35
  = f.label :notes, t('notes'), :class => "optional"
@@ -21,7 +21,6 @@
21
21
  %td.name
22
22
  = link_to image_tag(gravatar_url(user.email, :size=>"32px"), :class=>"avatar avatar_32x32", :width=>32, :height=>32, :alt=>""), edit_admin_user_url(user)
23
23
  = link_to user.name, edit_admin_user_url(user)
24
- %span.login (#{h user.login})
25
24
  - tbody.roles_cell do
26
25
  %td.roles= roles(user)
27
26
  - tbody.actions_cell do
@@ -0,0 +1,23 @@
1
+ - body_classes << 'password_form'
2
+ .login-form-content
3
+ .visual
4
+ = image_tag('/assets/admin/default_reset_password.svg', alt: 'person with hand to chin thoughtfully')
5
+ .login
6
+ %h1 Change your password
7
+ = form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f|
8
+ = f.hidden_field :reset_password_token
9
+ .field
10
+ = f.label :password, "New password"
11
+ %br/
12
+ - if @minimum_password_length
13
+ %em
14
+ (#{@minimum_password_length} characters minimum)
15
+ %br/
16
+ = f.password_field :password, autofocus: true, autocomplete: "new-password"
17
+ .field
18
+ = f.label :password_confirmation, "Confirm new password"
19
+ %br/
20
+ = f.password_field :password_confirmation, autocomplete: "new-password"
21
+ .actions
22
+ = f.submit "Change my password"
23
+ = render "devise/shared/links"
@@ -0,0 +1,14 @@
1
+ - body_classes << 'password_form'
2
+ .login-form-content
3
+ .visual
4
+ = image_tag('/assets/admin/default_forgot_password.svg', alt: 'person with hand to chin thoughtfully')
5
+ .login
6
+ %h1 Forgot your password?
7
+ = form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :post }) do |f|
8
+ .field
9
+ = f.label :email
10
+ %br/
11
+ = f.email_field :email, autofocus: true, autocomplete: "email"
12
+ .actions
13
+ = f.submit "Send me reset password instructions"
14
+ = render "devise/shared/links"
@@ -0,0 +1,25 @@
1
+ - body_classes << 'login_form'
2
+ .login-form-content
3
+ .visual
4
+ = image_tag('/assets/admin/default_safe_login.svg', alt: 'web browser with padlock on top')
5
+ .login
6
+ %h1 Log in
7
+ = form_for(resource, as: resource_name, url: session_path(resource_name)) do |f|
8
+ .field
9
+ = f.label :email
10
+ %br/
11
+ = f.email_field :email, autofocus: true, autocomplete: "email"
12
+ .field
13
+ = f.label :password
14
+ %br/
15
+ = f.password_field :password, autocomplete: "current-password"
16
+ - if devise_mapping.rememberable?
17
+ .field
18
+ = f.check_box :remember_me
19
+ = f.label :remember_me
20
+ .actions
21
+ = f.submit "Log in"
22
+ - if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations'
23
+ = link_to "Forgot your password?", new_password_path(resource_name)
24
+ - if flash.alert
25
+ .error= flash.alert
@@ -0,0 +1,16 @@
1
+ - if controller_name != 'sessions'
2
+ = link_to "Log in", new_session_path(resource_name)
3
+ %br/
4
+ - if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations'
5
+ = link_to "Forgot your password?", new_password_path(resource_name)
6
+ %br/
7
+ - if devise_mapping.confirmable? && controller_name != 'confirmations'
8
+ = link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name)
9
+ %br/
10
+ - if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks'
11
+ = link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name)
12
+ %br/
13
+ - if devise_mapping.omniauthable?
14
+ - resource_class.omniauth_providers.each do |provider|
15
+ = link_to "Sign in with #{OmniAuth::Utils.camelize(provider)}", omniauth_authorize_path(resource_name, provider)
16
+ %br/
@@ -35,7 +35,7 @@
35
35
  = render_region :before_nav
36
36
  - render_region :navigation do |navigation|
37
37
  #site_links
38
- = %{#{t('logged_in_as')} #{link_to h(current_user.name), edit_admin_preferences_path} &nbsp; (#{link_to t('log_out'), logout_path})}.html_safe
38
+ = %{#{t('logged_in_as')} #{link_to h(current_user.name), edit_admin_preferences_path} &nbsp; (#{link_to t('log_out'), destroy_user_session_path, method: :get})}.html_safe
39
39
  &nbsp;
40
40
  = link_to t('view_site'), root_path, :id=>"view_site"
41
41
  %ul#navigation
@@ -8,6 +8,7 @@ require 'trusty_cms/extension_loader'
8
8
  require 'trusty_cms/initializer'
9
9
  require 'rack/cache'
10
10
  require 'trustygems'
11
+ require 'devise'
11
12
 
12
13
 
13
14
  if defined?(Bundler)
@@ -0,0 +1,310 @@
1
+ require 'devise'
2
+
3
+ # frozen_string_literal: true
4
+
5
+ # Assuming you have not yet modified this file, each configuration option below
6
+ # is set to its default value. Note that some are commented out while others
7
+ # are not: uncommented lines are intended to protect your configuration from
8
+ # breaking changes in upgrades (i.e., in the event that future versions of
9
+ # Devise change the default values for those options).
10
+ #
11
+ # Use this hook to configure devise mailer, warden hooks and so forth.
12
+ # Many of these configuration options can be set straight in your model.
13
+ Devise.setup do |config|
14
+ # The secret key used by Devise. Devise uses this key to generate
15
+ # random tokens. Changing this key will render invalid all existing
16
+ # confirmation, reset password and unlock tokens in the database.
17
+ # Devise will use the `secret_key_base` as its `secret_key`
18
+ # by default. You can change it below and use your own secret key.
19
+ config.secret_key = 'abf03efc8b90c36f91df2f0bf3d0ea4baa2ffef2576ec2030db7b199f9972a7e5dfaa3814ab5ffb433e5b999b40e0b96fd7bc6abff074eb1a4ab4c6965092f58'
20
+
21
+ # ==> Controller configuration
22
+ # Configure the parent class to the devise controllers.
23
+ #config.parent_controller = 'ApplicationController'
24
+
25
+ # ==> Mailer Configuration
26
+ # Configure the e-mail address which will be shown in Devise::Mailer,
27
+ # note that it will be overwritten if you use your own mailer class
28
+ # with default "from" parameter.
29
+ config.mailer_sender = ENV['ORG_FROM_EMAIL'] ||= 'admin@trustycms.org'
30
+
31
+ # Configure the class responsible to send e-mails.
32
+ # config.mailer = 'Devise::Mailer'
33
+
34
+ # Configure the parent class responsible to send e-mails.
35
+ # config.parent_mailer = 'ActionMailer::Base'
36
+
37
+ # ==> ORM configuration
38
+ # Load and configure the ORM. Supports :active_record (default) and
39
+ # :mongoid (bson_ext recommended) by default. Other ORMs may be
40
+ # available as additional gems.
41
+ require 'devise/orm/active_record'
42
+
43
+ # ==> Configuration for any authentication mechanism
44
+ # Configure which keys are used when authenticating a user. The default is
45
+ # just :email. You can configure it to use [:username, :subdomain], so for
46
+ # authenticating a user, both parameters are required. Remember that those
47
+ # parameters are used only when authenticating and not when retrieving from
48
+ # session. If you need permissions, you should implement that in a before filter.
49
+ # You can also supply a hash where the value is a boolean determining whether
50
+ # or not authentication should be aborted when the value is not present.
51
+ # config.authentication_keys = [:email]
52
+
53
+ # Configure parameters from the request object used for authentication. Each entry
54
+ # given should be a request method and it will automatically be passed to the
55
+ # find_for_authentication method and considered in your model lookup. For instance,
56
+ # if you set :request_keys to [:subdomain], :subdomain will be used on authentication.
57
+ # The same considerations mentioned for authentication_keys also apply to request_keys.
58
+ # config.request_keys = []
59
+
60
+ # Configure which authentication keys should be case-insensitive.
61
+ # These keys will be downcased upon creating or modifying a user and when used
62
+ # to authenticate or find a user. Default is :email.
63
+ config.case_insensitive_keys = [:email]
64
+
65
+ # Configure which authentication keys should have whitespace stripped.
66
+ # These keys will have whitespace before and after removed upon creating or
67
+ # modifying a user and when used to authenticate or find a user. Default is :email.
68
+ config.strip_whitespace_keys = [:email]
69
+
70
+ # Tell if authentication through request.params is enabled. True by default.
71
+ # It can be set to an array that will enable params authentication only for the
72
+ # given strategies, for example, `config.params_authenticatable = [:database]` will
73
+ # enable it only for database (email + password) authentication.
74
+ # config.params_authenticatable = true
75
+
76
+ # Tell if authentication through HTTP Auth is enabled. False by default.
77
+ # It can be set to an array that will enable http authentication only for the
78
+ # given strategies, for example, `config.http_authenticatable = [:database]` will
79
+ # enable it only for database authentication.
80
+ # For API-only applications to support authentication "out-of-the-box", you will likely want to
81
+ # enable this with :database unless you are using a custom strategy.
82
+ # The supported strategies are:
83
+ # :database = Support basic authentication with authentication key + password
84
+ # config.http_authenticatable = false
85
+
86
+ # If 401 status code should be returned for AJAX requests. True by default.
87
+ # config.http_authenticatable_on_xhr = true
88
+
89
+ # The realm used in Http Basic Authentication. 'Application' by default.
90
+ # config.http_authentication_realm = 'Application'
91
+
92
+ # It will change confirmation, password recovery and other workflows
93
+ # to behave the same regardless if the e-mail provided was right or wrong.
94
+ # Does not affect registerable.
95
+ # config.paranoid = true
96
+
97
+ # By default Devise will store the user in session. You can skip storage for
98
+ # particular strategies by setting this option.
99
+ # Notice that if you are skipping storage for all authentication paths, you
100
+ # may want to disable generating routes to Devise's sessions controller by
101
+ # passing skip: :sessions to `devise_for` in your config/routes.rb
102
+ config.skip_session_storage = [:http_auth]
103
+
104
+ # By default, Devise cleans up the CSRF token on authentication to
105
+ # avoid CSRF token fixation attacks. This means that, when using AJAX
106
+ # requests for sign in and sign up, you need to get a new CSRF token
107
+ # from the server. You can disable this option at your own risk.
108
+ # config.clean_up_csrf_token_on_authentication = true
109
+
110
+ # When false, Devise will not attempt to reload routes on eager load.
111
+ # This can reduce the time taken to boot the app but if your application
112
+ # requires the Devise mappings to be loaded during boot time the application
113
+ # won't boot properly.
114
+ # config.reload_routes = true
115
+
116
+ # ==> Configuration for :database_authenticatable
117
+ # For bcrypt, this is the cost for hashing the password and defaults to 12. If
118
+ # using other algorithms, it sets how many times you want the password to be hashed.
119
+ #
120
+ # Limiting the stretches to just one in testing will increase the performance of
121
+ # your test suite dramatically. However, it is STRONGLY RECOMMENDED to not use
122
+ # a value less than 10 in other environments. Note that, for bcrypt (the default
123
+ # algorithm), the cost increases exponentially with the number of stretches (e.g.
124
+ # a value of 20 is already extremely slow: approx. 60 seconds for 1 calculation).
125
+ config.stretches = Rails.env.test? ? 1 : 12
126
+
127
+ # Set up a pepper to generate the hashed password.
128
+ # config.pepper = '<%= SecureRandom.hex(64) %>'
129
+
130
+ # Send a notification to the original email when the user's email is changed.
131
+ # config.send_email_changed_notification = false
132
+
133
+ # Send a notification email when the user's password is changed.
134
+ # config.send_password_change_notification = false
135
+
136
+ # ==> Configuration for :confirmable
137
+ # A period that the user is allowed to access the website even without
138
+ # confirming their account. For instance, if set to 2.days, the user will be
139
+ # able to access the website for two days without confirming their account,
140
+ # access will be blocked just in the third day.
141
+ # You can also set it to nil, which will allow the user to access the website
142
+ # without confirming their account.
143
+ # Default is 0.days, meaning the user cannot access the website without
144
+ # confirming their account.
145
+ # config.allow_unconfirmed_access_for = 2.days
146
+
147
+ # A period that the user is allowed to confirm their account before their
148
+ # token becomes invalid. For example, if set to 3.days, the user can confirm
149
+ # their account within 3 days after the mail was sent, but on the fourth day
150
+ # their account can't be confirmed with the token any more.
151
+ # Default is nil, meaning there is no restriction on how long a user can take
152
+ # before confirming their account.
153
+ # config.confirm_within = 3.days
154
+
155
+ # If true, requires any email changes to be confirmed (exactly the same way as
156
+ # initial account confirmation) to be applied. Requires additional unconfirmed_email
157
+ # db field (see migrations). Until confirmed, new email is stored in
158
+ # unconfirmed_email column, and copied to email column on successful confirmation.
159
+ # config.reconfirmable = true
160
+
161
+ # Defines which key will be used when confirming an account
162
+ # config.confirmation_keys = [:email]
163
+
164
+ # ==> Configuration for :rememberable
165
+ # The time the user will be remembered without asking for credentials again.
166
+ # config.remember_for = 2.weeks
167
+
168
+ # Invalidates all the remember me tokens when the user signs out.
169
+ config.expire_all_remember_me_on_sign_out = true
170
+
171
+ # If true, extends the user's remember period when remembered via cookie.
172
+ # config.extend_remember_period = false
173
+
174
+ # Options to be passed to the created cookie. For instance, you can set
175
+ # secure: true in order to force SSL only cookies.
176
+ # config.rememberable_options = {}
177
+
178
+ # ==> Configuration for :validatable
179
+ # Range for password length.
180
+ # config.password_length = 12..128
181
+
182
+ # Email regex used to validate email formats. It simply asserts that
183
+ # one (and only one) @ exists in the given string. This is mainly
184
+ # to give user feedback and not to assert the e-mail validity.
185
+ config.email_regexp = /\A[^@\s]+@[^@\s]+\z/
186
+
187
+ # ==> Configuration for :timeoutable
188
+ # The time you want to timeout the user session without activity. After this
189
+ # time the user will be asked for credentials again. Default is 30 minutes.
190
+ # config.timeout_in = 30.minutes
191
+
192
+ # ==> Configuration for :lockable
193
+ # Defines which strategy will be used to lock an account.
194
+ # :failed_attempts = Locks an account after a number of failed attempts to sign in.
195
+ # :none = No lock strategy. You should handle locking by yourself.
196
+ # config.lock_strategy = :failed_attempts
197
+
198
+ # Defines which key will be used when locking and unlocking an account
199
+ # config.unlock_keys = [:email]
200
+
201
+ # Defines which strategy will be used to unlock an account.
202
+ # :email = Sends an unlock link to the user email
203
+ # :time = Re-enables login after a certain amount of time (see :unlock_in below)
204
+ # :both = Enables both strategies
205
+ # :none = No unlock strategy. You should handle unlocking by yourself.
206
+ # config.unlock_strategy = :both
207
+
208
+ # Number of authentication tries before locking an account if lock_strategy
209
+ # is failed attempts.
210
+ # config.maximum_attempts = 20
211
+
212
+ # Time interval to unlock the account if :time is enabled as unlock_strategy.
213
+ # config.unlock_in = 1.hour
214
+
215
+ # Warn on the last attempt before the account is locked.
216
+ # config.last_attempt_warning = true
217
+
218
+ # ==> Configuration for :recoverable
219
+ #
220
+ # Defines which key will be used when recovering the password for an account
221
+ # config.reset_password_keys = [:email]
222
+
223
+ # Time interval you can reset your password with a reset password key.
224
+ # Don't put a too small interval or your users won't have the time to
225
+ # change their passwords.
226
+ config.reset_password_within = 6.hours
227
+
228
+ # When set to false, does not sign a user in automatically after their password is
229
+ # reset. Defaults to true, so a user is signed in automatically after a reset.
230
+ # config.sign_in_after_reset_password = true
231
+
232
+ # ==> Configuration for :encryptable
233
+ # Allow you to use another hashing or encryption algorithm besides bcrypt (default).
234
+ # You can use :sha1, :sha512 or algorithms from others authentication tools as
235
+ # :clearance_sha1, :authlogic_sha512 (then you should set stretches above to 20
236
+ # for default behavior) and :restful_authentication_sha1 (then you should set
237
+ # stretches to 10, and copy REST_AUTH_SITE_KEY to pepper).
238
+ #
239
+ # Require the `devise-encryptable` gem when using anything other than bcrypt
240
+ # config.encryptor = :sha512
241
+
242
+ # ==> Scopes configuration
243
+ # Turn scoped views on. Before rendering "sessions/new", it will first check for
244
+ # "users/sessions/new". It's turned off by default because it's slower if you
245
+ # are using only default views.
246
+ # config.scoped_views = false
247
+
248
+ # Configure the default scope given to Warden. By default it's the first
249
+ # devise role declared in your routes (usually :user).
250
+ # config.default_scope = :user
251
+
252
+ # Set this configuration to false if you want /users/sign_out to sign out
253
+ # only the current scope. By default, Devise signs out all scopes.
254
+ # config.sign_out_all_scopes = true
255
+
256
+ # ==> Navigation configuration
257
+ # Lists the formats that should be treated as navigational. Formats like
258
+ # :html, should redirect to the sign in page when the user does not have
259
+ # access, but formats like :xml or :json, should return 401.
260
+ #
261
+ # If you have any extra navigational formats, like :iphone or :mobile, you
262
+ # should add them to the navigational formats lists.
263
+ #
264
+ # The "*/*" below is required to match Internet Explorer requests.
265
+ # config.navigational_formats = ['*/*', :html]
266
+
267
+ # The default HTTP method used to sign out a resource. Default is :delete.
268
+ config.sign_out_via = :get
269
+
270
+ # ==> OmniAuth
271
+ # Add a new OmniAuth provider. Check the wiki for more information on setting
272
+ # up on your models and hooks.
273
+ # config.omniauth :github, 'APP_ID', 'APP_SECRET', scope: 'user,public_repo'
274
+
275
+ # ==> Warden configuration
276
+ # If you want to use other strategies, that are not supported by Devise, or
277
+ # change the failure app, you can configure them inside the config.warden block.
278
+ #
279
+ # config.warden do |manager|
280
+ # manager.intercept_401 = false
281
+ # manager.default_strategies(scope: :user).unshift :some_external_strategy
282
+ # end
283
+
284
+ # ==> Mountable engine configurations
285
+ # When using Devise inside an engine, let's call it `MyEngine`, and this engine
286
+ # is mountable, there are some extra configurations to be taken into account.
287
+ # The following options are available, assuming the engine is mounted as:
288
+ #
289
+ # mount MyEngine, at: '/my_engine'
290
+ #
291
+ # The router that invoked `devise_for`, in the example above, would be:
292
+ # config.router_name = :trusty_cms
293
+ #
294
+ # When using OmniAuth, Devise cannot automatically set OmniAuth path,
295
+ # so you need to do it manually. For the users scope, it would be:
296
+ # config.omniauth_path_prefix = '/my_engine/users/auth'
297
+
298
+ # ==> Turbolinks configuration
299
+ # If your app is using Turbolinks, Turbolinks::Controller needs to be included to make redirection work correctly:
300
+ #
301
+ # ActiveSupport.on_load(:devise_failure_app) do
302
+ # include Turbolinks::Controller
303
+ # end
304
+
305
+ # ==> Configuration for :registerable
306
+
307
+ # When set to false, does not sign a user in automatically after their password is
308
+ # changed. Defaults to true, so a user is signed in automatically after changing a password.
309
+ # config.sign_in_after_change_password = true
310
+ end