mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
Patch actionNames on getWorkspacelogs
This commit is contained in:
@@ -41,10 +41,11 @@ export const getWorkspaceLogs = async (req: Request, res: Response) => {
|
||||
let logs
|
||||
try {
|
||||
const { workspaceId } = req.params;
|
||||
const { userId, actionNames } = req.query;
|
||||
|
||||
const offset: number = parseInt(req.query.offset as string);
|
||||
const limit: number = parseInt(req.query.limit as string);
|
||||
const userId: string = req.query.userId as string;
|
||||
const actionNames: string = req.query.actionNames as string;
|
||||
|
||||
logs = await Log.find({
|
||||
workspace: workspaceId,
|
||||
@@ -53,7 +54,7 @@ export const getWorkspaceLogs = async (req: Request, res: Response) => {
|
||||
actionNames
|
||||
? {
|
||||
actionNames: {
|
||||
$in: actionNames
|
||||
$in: actionNames.split(',')
|
||||
}
|
||||
} : {}
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user