rename variable requestJson when it's not actually json

This commit is contained in:
Shpuld Shpuldson 2020-06-27 12:59:24 +03:00
parent a8cb5e71d9
commit 46cf50a4d6
1 changed files with 3 additions and 3 deletions

View File

@ -25,11 +25,11 @@ const preloadFetch = async (request) => {
if (!data || !data[request]) { if (!data || !data[request]) {
return window.fetch(request) return window.fetch(request)
} }
const requestJson = atob(data[request]) const requestData = atob(data[request])
return { return {
ok: true, ok: true,
json: () => JSON.parse(requestJson), json: () => JSON.parse(requestData),
text: () => requestJson text: () => requestData
} }
} }