Skip to content

Commit 43b24dd

Browse files
Merge pull request #17 from TerbiumOS/lemonade
Lemonade
2 parents e5051fc + d6fdbd6 commit 43b24dd

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

public/apps/app store.tapp/index.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,15 @@ async function loadApp(app, type) {
179179
break;
180180
case "Anura":
181181
case "tb-liq":
182-
const icn2 = await window.parent.tb.libcurl.fetch(`${currRepo.url.replace("manifest.json", "")}/apps/${app.package}/${app.icon}`);
182+
let icn2;
183+
if (currRepo.url) {
184+
icn2 = await window.parent.tb.libcurl.fetch(`${currRepo.url.replace("manifest.json", "")}/apps/${app.package}/${app.icon}`);
185+
} else {
186+
icn2 = await window.parent.tb.libcurl.fetch(app.icon);
187+
}
188+
if (!icn2.ok) {
189+
icn2 = await window.parent.tb.libcurl.fetch("https://terbiumon.top/favicon.ico");
190+
}
183191
const blob2 = await icn2.blob();
184192
icnUrl = URL.createObjectURL(blob2);
185193
break;
@@ -461,7 +469,7 @@ async function addRepo() {
461469
const list = await window.parent.tb.libcurl.fetch(value.replace("manifest.json", "list.json"));
462470
if (list.ok) {
463471
repos.push({
464-
name: name || meta.name || "Unknown",
472+
name: meta.name || "Unknown",
465473
url: value,
466474
icon: "https://anura.pro/icon.png",
467475
});

0 commit comments

Comments
 (0)