Permalink
Browse files

Add documentation for `config.redirect_url`

  • Loading branch information...
1 parent 75e6218 commit d1700fadca5a4bcd60b2ce0be6cd7f552b4eadf5 @croaky croaky committed Mar 26, 2013
Showing with 14 additions and 1 deletion.
  1. +14 −1 README.md
View
15 README.md
@@ -59,7 +59,7 @@ Override any of these defaults in `config/initializers/clearance.rb`:
config.mailer_sender = 'reply@example.com'
config.password_strategy = Clearance::PasswordStrategies::BCrypt
config.user_model = User
- config.redirect_path = '/'
+ config.redirect_url = '/'
end
Use
@@ -181,6 +181,19 @@ Or, override private methods:
users#url_after_create
users#user_from_params
+All of these controller methods redirect to `'/'` by default:
+
+ passwords#url_after_update
+ sessions#url_after_create
+ users#url_after_create
+ application#url_after_denied_access_when_signed_in
+
+To override them all at once, change the global configuration:
+
+ Clearance.configure do |config|
+ config.redirect_url = '/overriden'
+ end
+
Overriding translations
-----------------------

0 comments on commit d1700fa

Please sign in to comment.