diff --git a/server/api/routes.js b/server/api/routes.js index 7265044a76..6a8561054f 100644 --- a/server/api/routes.js +++ b/server/api/routes.js @@ -487,7 +487,6 @@ function getRoutes(gladys) { }, 'get /api/v1/session': { authenticated: true, - admin: true, controller: sessionController.get, }, // light diff --git a/server/lib/session/session.get.js b/server/lib/session/session.get.js index 90fe07e1eb..13307cbbba 100644 --- a/server/lib/session/session.get.js +++ b/server/lib/session/session.get.js @@ -37,6 +37,7 @@ async function get(userId, options) { order: [[optionsWithDefault.order_by, optionsWithDefault.order_dir]], where: { revoked: false, + user_id: userId, }, });