feat(audit-logging): Replace req.session with req.auth for audit logging in notes and projects
This commit is contained in:
@@ -32,7 +32,7 @@ async function getProjectHandler(req, { params }) {
|
||||
AUDIT_ACTIONS.PROJECT_VIEW,
|
||||
RESOURCE_TYPES.PROJECT,
|
||||
id,
|
||||
req.session,
|
||||
req.auth, // Use req.auth instead of req.session
|
||||
{ project_name: project.project_name }
|
||||
);
|
||||
|
||||
@@ -60,7 +60,7 @@ async function updateProjectHandler(req, { params }) {
|
||||
AUDIT_ACTIONS.PROJECT_UPDATE,
|
||||
RESOURCE_TYPES.PROJECT,
|
||||
id,
|
||||
req.session,
|
||||
req.auth, // Use req.auth instead of req.session
|
||||
{
|
||||
originalData: originalProject,
|
||||
updatedData: data,
|
||||
@@ -85,7 +85,7 @@ async function deleteProjectHandler(req, { params }) {
|
||||
AUDIT_ACTIONS.PROJECT_DELETE,
|
||||
RESOURCE_TYPES.PROJECT,
|
||||
id,
|
||||
req.session,
|
||||
req.auth, // Use req.auth instead of req.session
|
||||
{
|
||||
deletedProject: {
|
||||
project_name: project?.project_name,
|
||||
|
||||
Reference in New Issue
Block a user