fixed icons now loading
This commit is contained in:
parent
3dc582d1f0
commit
d6e9f5f649
1 changed files with 8 additions and 2 deletions
|
@ -598,11 +598,17 @@ class IconManager {
|
||||||
async resolve_icon(id: number) : Promise<Icon> {
|
async resolve_icon(id: number) : Promise<Icon> {
|
||||||
id = id >>> 0;
|
id = id >>> 0;
|
||||||
try {
|
try {
|
||||||
return await this.resolved_cached(id);
|
const result = await this.resolved_cached(id);
|
||||||
|
if(result)
|
||||||
|
return result;
|
||||||
|
throw "";
|
||||||
} catch(error) { }
|
} catch(error) { }
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return await this.download_icon(id);
|
const result = await this.download_icon(id);
|
||||||
|
if(result)
|
||||||
|
return result;
|
||||||
|
throw "load result is empty";
|
||||||
} catch(error) {
|
} catch(error) {
|
||||||
console.error(tr("Icon download failed of icon %d: %o"), id, error);
|
console.error(tr("Icon download failed of icon %d: %o"), id, error);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue