Can delete an OTA update
This commit is contained in:
@ -40,8 +40,18 @@ export class OTAAPI {
|
||||
/**
|
||||
* Get the link to download an OTA update
|
||||
*/
|
||||
static DownloadOTAUpdateURL(platform: string, version: string): string {
|
||||
return APIClient.backendURL() + `/ota/${platform}/${version}`;
|
||||
static DownloadOTAUpdateURL(update: OTAUpdate): string {
|
||||
return APIClient.backendURL() + `/ota/${update.platform}/${update.version}`;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete an update
|
||||
*/
|
||||
static async DeleteUpdate(update: OTAUpdate): Promise<void> {
|
||||
await APIClient.exec({
|
||||
method: "DELETE",
|
||||
uri: `/ota/${update.platform}/${update.version}`,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user