Skip to content
This repository was archived by the owner on Sep 2, 2024. It is now read-only.

Commit 8f49c82

Browse files
committed
added delete file function
1 parent 0873fb4 commit 8f49c82

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

storage.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,8 @@ func DownloadFile(token, fileURL string) ([]byte, error) {
4444
err = Get(token, u.Path, &buf)
4545
return buf, err
4646
}
47+
48+
func DeleteFile(token, id string) (ok bool, err error) {
49+
err = Get(token, fmt.Sprintf("/sudostorage/delete?id=%s", id), &ok)
50+
return
51+
}

0 commit comments

Comments
 (0)