so thats why you dont work

This commit is contained in:
May 2023-05-09 23:00:17 -07:00
parent d916247e0d
commit b82577e1a8
3 changed files with 5 additions and 4 deletions

View file

@ -78,6 +78,7 @@ fileApiRoutes.post("/manage", parser, (req,res) => {
writeFile(process.cwd()+"/.data/files.json",JSON.stringify(files.files), (err) => {
if (err) console.log(err)
res.contentType("text/plain")
res.send(`modified ${modified} files`)
})

View file

@ -1,4 +1,4 @@
import { fetchAccountData, account } from "../stores.mjs"
import { fetchAccountData, fetchFilePointers, account } from "../stores.mjs"
import { get } from "svelte/store";
export let options = {
@ -132,7 +132,7 @@ export function fileOptions(optPicker,file) {
optPicker.picker(`${response.status} ${response.statusText}`,[])
}
fetchFilePointers()
fetchFilePointers();
})
break;
@ -154,7 +154,7 @@ export function fileOptions(optPicker,file) {
optPicker.picker(`${response.status} ${response.statusText}`,[])
}
fetchFilePointers()
fetchFilePointers();
})
}

View file

@ -16,7 +16,7 @@ export let fetchAccountData = function() {
}
export let fetchFilePointers = function() {
fetch("/files/list").then(async (response) => {
fetch("/files/list", { cache: "no-cache" }).then(async (response) => {
if (response.status == 200) {
files.set(await response.json())
} else {