mirror of
https://github.com/bitwarden/browser
synced 2025-12-06 00:13:28 +00:00
[PM-19383] admins unable to download attachments (#14363)
* add admin support for downloading attachments * fix delete and upload * fix delete admin to return a response * fix upload * add missing param * use getCipherAdmin * fix cli
This commit is contained in:
@@ -637,6 +637,15 @@ export class ApiService implements ApiServiceAbstraction {
|
||||
return new AttachmentResponse(r);
|
||||
}
|
||||
|
||||
async getAttachmentDataAdmin(
|
||||
cipherId: string,
|
||||
attachmentId: string,
|
||||
): Promise<AttachmentResponse> {
|
||||
const path = "/ciphers/" + cipherId + "/attachment/" + attachmentId + "/admin";
|
||||
const r = await this.send("GET", path, null, true, true);
|
||||
return new AttachmentResponse(r);
|
||||
}
|
||||
|
||||
async postCipherAttachment(
|
||||
id: string,
|
||||
request: AttachmentRequest,
|
||||
@@ -673,7 +682,7 @@ export class ApiService implements ApiServiceAbstraction {
|
||||
"/ciphers/" + id + "/attachment/" + attachmentId + "/admin",
|
||||
null,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user