forked from thoughtbot/clearance
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow User model to be reloaded in development
When a `user_model` is configured in a Clearance initializer, a reference to that class is immediately saved off. If that class is changed, Clearance will not know to automatically reload the class as Rails does automatically for classes in development. This change introduces a `to_prepare` block to the Engine that is responsible for forcing the configured user class to be reloaded. `to_prepare` runs once per request in development and only at startup in other environments.
- Loading branch information
1 parent
53f13ed
commit 0181691
Showing
3 changed files
with
30 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters