mirror of
https://github.com/mollersuite/monofile.git
synced 2024-11-22 05:46:26 -08:00
so thats why you dont work
This commit is contained in:
parent
d916247e0d
commit
b82577e1a8
|
@ -78,6 +78,7 @@ fileApiRoutes.post("/manage", parser, (req,res) => {
|
||||||
|
|
||||||
writeFile(process.cwd()+"/.data/files.json",JSON.stringify(files.files), (err) => {
|
writeFile(process.cwd()+"/.data/files.json",JSON.stringify(files.files), (err) => {
|
||||||
if (err) console.log(err)
|
if (err) console.log(err)
|
||||||
|
res.contentType("text/plain")
|
||||||
res.send(`modified ${modified} files`)
|
res.send(`modified ${modified} files`)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { fetchAccountData, account } from "../stores.mjs"
|
import { fetchAccountData, fetchFilePointers, account } from "../stores.mjs"
|
||||||
import { get } from "svelte/store";
|
import { get } from "svelte/store";
|
||||||
|
|
||||||
export let options = {
|
export let options = {
|
||||||
|
@ -132,7 +132,7 @@ export function fileOptions(optPicker,file) {
|
||||||
optPicker.picker(`${response.status} ${response.statusText}`,[])
|
optPicker.picker(`${response.status} ${response.statusText}`,[])
|
||||||
}
|
}
|
||||||
|
|
||||||
fetchFilePointers()
|
fetchFilePointers();
|
||||||
})
|
})
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@ -154,7 +154,7 @@ export function fileOptions(optPicker,file) {
|
||||||
optPicker.picker(`${response.status} ${response.statusText}`,[])
|
optPicker.picker(`${response.status} ${response.statusText}`,[])
|
||||||
}
|
}
|
||||||
|
|
||||||
fetchFilePointers()
|
fetchFilePointers();
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@ export let fetchAccountData = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
export let fetchFilePointers = function() {
|
export let fetchFilePointers = function() {
|
||||||
fetch("/files/list").then(async (response) => {
|
fetch("/files/list", { cache: "no-cache" }).then(async (response) => {
|
||||||
if (response.status == 200) {
|
if (response.status == 200) {
|
||||||
files.set(await response.json())
|
files.set(await response.json())
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue