updated to version 0.1.26
This commit is contained in:
parent
5d583ed6d8
commit
053a2e9ec9
@ -6,7 +6,7 @@
|
|||||||
"authors": [
|
"authors": [
|
||||||
{ "name": "Robin Riis" }
|
{ "name": "Robin Riis" }
|
||||||
],
|
],
|
||||||
"version": "0.1.25",
|
"version": "0.1.26",
|
||||||
"socket": true,
|
"socket": true,
|
||||||
"minimumCoreVersion": 10,
|
"minimumCoreVersion": 10,
|
||||||
"compatibility": {
|
"compatibility": {
|
||||||
|
|||||||
@ -7,12 +7,13 @@ export class PuckoPruttApi {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async _fetch_json(url) {
|
async _fetch_json(url) {
|
||||||
const response = await fetch(this.apiUrl + url);
|
ret = "Could not fetch "+url
|
||||||
if (!response.ok) {
|
const response = await fetch(this.apiUrl + url).then(
|
||||||
return -1;
|
response => response.json()
|
||||||
}
|
).then(data => ret = data).catch(
|
||||||
const json = await response.json();
|
error => console.error("Error: ", error)
|
||||||
return json;
|
);
|
||||||
|
return ret
|
||||||
}
|
}
|
||||||
|
|
||||||
async dagens_lunch(spider) {
|
async dagens_lunch(spider) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user