add delete
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@kevisual/api",
|
||||
"version": "0.0.29",
|
||||
"version": "0.0.30",
|
||||
"description": "",
|
||||
"main": "mod.ts",
|
||||
"scripts": {
|
||||
|
||||
@@ -79,6 +79,14 @@ export class QueryResources {
|
||||
body: formData,
|
||||
});
|
||||
}
|
||||
async deleteFile(filepath: string, opts?: DataOpts): Promise<Result<any>> {
|
||||
const url = `${this.prefix}${filepath}`;
|
||||
return adapter({
|
||||
url,
|
||||
method: 'DELETE' as any,
|
||||
headers: this.header(opts?.headers),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
export const getContentType = (filename: string): string => {
|
||||
|
||||
Reference in New Issue
Block a user