Update screenshot.js

This commit is contained in:
Alex / Awex
2021-07-14 09:20:38 -04:00
parent cef98653e8
commit afe96a2c52
+3 -3
View File
@@ -1,8 +1,8 @@
async function getFileUrl() {
const params = new URLSearchParams(window.location.search)
let title = params.get('photo')
let apiurl = `http://${window.location.host}/screenshots?title=${title}`
let pageURL = `http://${window.location.host}/view?photo=${title}`
let apiurl = `https://${window.location.host}/screenshots?title=${title}`
let pageURL = `https://${window.location.host}/view?photo=${title}`
if(title) {
try{
@@ -37,7 +37,7 @@ async function getFileUrl() {
const params = new URLSearchParams(window.location.search)
let title = params.get('photo')
var secret = document.querySelector("#secret").value
const delfile = await fetch(`http://${window.location.host}/delete/${title}`, {
const delfile = await fetch(`https://${window.location.host}/delete/${title}`, {
method: "DELETE",
headers: { "secret": `${secret}`}
})