fixed icons now loading

canary
WolverinDEV 2019-05-25 21:20:48 +02:00
parent 3dc582d1f0
commit d6e9f5f649
1 changed files with 8 additions and 2 deletions

View File

@ -598,11 +598,17 @@ class IconManager {
async resolve_icon(id: number) : Promise<Icon> {
id = id >>> 0;
try {
return await this.resolved_cached(id);
const result = await this.resolved_cached(id);
if(result)
return result;
throw "";
} catch(error) { }
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) {
console.error(tr("Icon download failed of icon %d: %o"), id, error);
}