mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 14:23:32 +00:00
Output user-specific associations for collections in the CLI (#10154)
Collection management permissions can be set for a group or a specific user. Currently the CLI only outputs group associations when it displays collection configuration information. This can cause bugs when piping commands together. This commit ensures that `user` associations also get output. In all cases this data was already available and just needed to be added to a response model.
This commit is contained in:
@@ -456,7 +456,13 @@ export class GetCommand extends DownloadCommand {
|
||||
: response.groups.map(
|
||||
(g) => new SelectionReadOnly(g.id, g.readOnly, g.hidePasswords, g.manage),
|
||||
);
|
||||
const res = new OrganizationCollectionResponse(decCollection, groups);
|
||||
const users =
|
||||
response.users == null
|
||||
? null
|
||||
: response.users.map(
|
||||
(g) => new SelectionReadOnly(g.id, g.readOnly, g.hidePasswords, g.manage),
|
||||
);
|
||||
const res = new OrganizationCollectionResponse(decCollection, groups, users);
|
||||
return Response.success(res);
|
||||
} catch (e) {
|
||||
return Response.error(e);
|
||||
|
||||
Reference in New Issue
Block a user