fix:delete profileAvatar
All checks were successful
Build & Deploy on Dev / build (push) Successful in 53s

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2026-01-30 14:47:46 +07:00
parent e461f43604
commit 633ccd4906
4 changed files with 67 additions and 0 deletions

View file

@ -99,6 +99,23 @@ class CallAPI {
throw error;
}
}
//Delete File
public async DeleteFile(request: any, @Path() path: any) {
const token = "Bearer " + request.headers.authorization.replace("Bearer ", "");
const url = process.env.API_URL + "/salary/file/" + path;
try {
await axios.delete(url, {
headers: {
Authorization: `${token}`,
"Content-Type": "application/json",
api_key: process.env.API_KEY,
},
});
} catch (error) {
throw error;
}
}
}
export default CallAPI;