]> git.example.dev Git - binbsis50-sm.git/commitdiff
updated: to not use json.stringify, just so it all works and is easier
author2weiEmu <saalbach.robert@outlook.de>
Tue, 2 Jun 2026 17:51:15 +0000 (19:51 +0200)
committer2weiEmu <saalbach.robert@outlook.de>
Tue, 2 Jun 2026 17:51:15 +0000 (19:51 +0200)
pkg/dbhandling/filesapi.go
public/js/index.js
songmanager
testing/songs/elastic_heart [deleted file]
testing/songs/elastic_heart.m4a
testing/songs/elastic_heart_sia [deleted file]

index 20b62e6682d447df4d993fa0616648c580319a16..869b9f7358bfcc433f6f59f71531e8e1e390e198 100644 (file)
@@ -59,6 +59,7 @@ func (dbw *DBWrapper) FilesCreateWithURL(w http.ResponseWriter, r *http.Request)
 
        resp, err := http.Get(url)
        if (err != nil) || (resp.Status != "200 OK") {
+               _ = os.Remove(dbw.PathToSongs + "/" + filename)
                fmt.Println("Error", err)
                w.WriteHeader(http.StatusNotFound)
                return
index cf128b6ce1966001026e238d567d0fa304551eab..62028c56c526e389da24a2c5fca8cf910762d792 100644 (file)
@@ -371,7 +371,7 @@ async function uploadFileWithLinkAndName() {
 
        let response = await fetch("/api/files/createWithURL/" + name, {
                method: "POST",
-               body: JSON.stringify(link)
+               body: link
        })
 
        if (response.status != 200) {
index c1f2926ab7b0061982c00ba8b7360aa62db90933..5f55f2091ef936bef413cb6e5ea92ff06bde196a 100755 (executable)
Binary files a/songmanager and b/songmanager differ
diff --git a/testing/songs/elastic_heart b/testing/songs/elastic_heart
deleted file mode 100644 (file)
index e69de29..0000000
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..2cdcb4b23fc6274c765326905aaea9bdf9384a43 100644 (file)
Binary files a/testing/songs/elastic_heart.m4a and b/testing/songs/elastic_heart.m4a differ
diff --git a/testing/songs/elastic_heart_sia b/testing/songs/elastic_heart_sia
deleted file mode 100644 (file)
index e69de29..0000000