-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SDP-1032] Add logs for any changes in user profile or the organizati…
…on profile (#145) ### What Start logging important changes on user or organization profiles, for traceability. Here are the functions that are now being logged: - Changes made through `PatchOrganizationProfile` - Log message: `log.Ctx(ctx).Warnf("[PatchOrganizationProfile] - userID %s will update the organization fields %v", user.ID, nonEmptyKeys)` - Changes made through `PatchUserProfile` - Log message: `log.Ctx(ctx).Warnf("[PatchUserProfile] - Will update email for userID %s to %s", user.ID, utils.TruncateString(reqBody.Email, 3))` - Changes made through `PatchUserPassword` - Log message: `log.Ctx(ctx).Warnf("[UpdateUserPassword] - Will update password for user account ID %s", user.ID)` Also, refactored some tests. ### Why So we can better track changes made in user profiles or Organization profiles, for accountability.
- Loading branch information
1 parent
fe3e148
commit ce0d6a8
Showing
3 changed files
with
777 additions
and
1,068 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
Oops, something went wrong.