diff --git a/CHANGELOG.md b/CHANGELOG.md index 213b65852..a1cd3d803 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,3 +6,4 @@ Changed for individual apps are listed in `apps/appname/ChangeLog` * `Remove All Apps` now doesn't perform a reset before erase - fixes inability to update firmware if settings are wrong * Added optional `README.md` file for apps * Remove 2v04 version warning, add links in About to official/developer versions +* Fix issue removing an app that was just installed (Fix #253) diff --git a/js/comms.js b/js/comms.js index eb453871d..12989e089 100644 --- a/js/comms.js +++ b/js/comms.js @@ -16,6 +16,11 @@ uploadApp : (app,skipReset) => { // expects an apps.json structure (i.e. with `s var maxBytes = fileContents.reduce((b,f)=>b+f.content.length, 0)||1; var currentBytes = 0; + var appInfoFileName = app.id+".info"; + var appInfoFile = fileContents.find(f=>f.name==appInfoFileName); + if (!appInfoFile) reject(`${appInfoFileName} not found`); + var appInfo = JSON.parse(appInfoFile.content); + // Upload each file one at a time function doUploadFiles() { // No files left - print 'reboot' message @@ -23,7 +28,7 @@ uploadApp : (app,skipReset) => { // expects an apps.json structure (i.e. with `s Puck.write(`\x10E.showMessage('Hold BTN3\\nto reload')\n`,(result) => { Progress.hide({sticky:true}); if (result===null) return reject(""); - resolve(app); + resolve(appInfo); }); return; }