mirror of https://github.com/bastienwirtz/homer
wait for `fetchServerStatus` before calling `fetchServerStats`
parent
ce4d3a3dbe
commit
8f7752a0b8
|
@ -80,14 +80,14 @@ export default {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.fetchServerStatus();
|
this.fetchServerStatus().then(() => {
|
||||||
|
|
||||||
if (!this.item.subtitle && this.status !== "dead") {
|
if (!this.item.subtitle && this.status !== "dead") {
|
||||||
if (!this.item.items) this.item.items = ["name", "version"];
|
if (!this.item.items) this.item.items = ["name", "version"];
|
||||||
if (!this.item.separator) this.item.separator = " ";
|
if (!this.item.separator) this.item.separator = " ";
|
||||||
if (!this.item.logo) this.item.logo = `${this.item.url}/static/icons/favicon-192x192.png`;
|
if (!this.item.logo) this.item.logo = `${this.item.url}/static/icons/favicon-192x192.png`;
|
||||||
this.fetchServerStats();
|
this.fetchServerStats();
|
||||||
}
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
fetchServerStatus: async function () {
|
fetchServerStatus: async function () {
|
||||||
|
|
Loading…
Reference in New Issue