mirror of
https://github.com/LCPQ/QUESTDB_website.git
synced 2025-01-12 14:08:28 +01:00
Fix RequestHeader
This commit is contained in:
parent
b171001b38
commit
52f536a654
@ -1,8 +1,10 @@
|
||||
async function getTextFromFileUrlAsync(url) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
var req = new XMLHttpRequest();
|
||||
req.setRequestHeader("Cache-Control: no-cache, no-store, must-revalidate")
|
||||
req.open("GET",url, true);
|
||||
for (const item of ["no-cache","no-store","must-revalidate"]) {
|
||||
req.setRequestHeader("Cache-Control",item)
|
||||
}
|
||||
req.onreadystatechange = function() {
|
||||
if (req.readyState == 4) {
|
||||
if (req.status == 200) {//when a good response is given do this
|
||||
|
Loading…
Reference in New Issue
Block a user