Skip to content

Commit fdc9de2

Browse files
committed
Fix regression in app namings
1 parent 8c25733 commit fdc9de2

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

js/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -864,7 +864,7 @@ function removeApp(app) {
864864
/** Show window for a new app and finally upload it */
865865
function customApp(app) {
866866
return handleCustomApp(app).then(() => {
867-
showToast(`${Utils.formatAppName()} Uploaded!`, "success");
867+
showToast(`${Utils.formatAppName(app)} Uploaded!`, "success");
868868
refreshMyApps();
869869
refreshLibrary();
870870
}).catch(err => {

js/utils.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -517,6 +517,7 @@ function parseRJSON(str) {
517517

518518
/** Format app name into a string like "App Name (AppID)" */
519519
function formatAppName(app){
520+
if (!app) return "";
520521
if (!app.name) return app.id; // just in case we don't have name (eg when removing)
521522
// check if id is the same as the name, in which case we can just return the name...
522523
if(app.name.trim().toLowerCase()===app.id.trim().toLowerCase()){

0 commit comments

Comments
 (0)