mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-04-03 22:37:20 +02:00
fix: paginate listRoles, null-guard permissions handler, fix export ordering
- Add limit/offset/total pagination to listRoles matching the groups pattern - Add countRoles data-layer method - Omit permissions from listRoles select (getRole returns full document) - Null-guard re-fetched role in updateRolePermissionsHandler - Move interleaved export below all imports in methods/index.ts
This commit is contained in:
parent
2a4cbfa41a
commit
2506644d58
5 changed files with 62 additions and 11 deletions
|
|
@ -13,6 +13,7 @@ const requireManageRoles = requireCapability(SystemCapabilities.MANAGE_ROLES);
|
|||
|
||||
const handlers = createAdminRolesHandlers({
|
||||
listRoles: db.listRoles,
|
||||
countRoles: db.countRoles,
|
||||
getRoleByName: db.getRoleByName,
|
||||
createRoleByName: db.createRoleByName,
|
||||
updateRoleByName: db.updateRoleByName,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue