forked from collectiveidea/audited
-
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.
Call controller's current_user method during audited model creation
Restores behaviour prior to 87d402a where the sweeper would call the controller's current_user method from the audited model callback. Since 87d402a, the current_user method was called from an around action callback registered on the base controller which was being called prior to other callbacks that were authenticating the user. This caused problems in apps where the user hadn't yet been set (so audit users were nil), or CSRF issues because current_user was called prior to session changes. Fixes collectiveidea#336
- Loading branch information
Showing
3 changed files
with
22 additions
and
2 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