Created attachment 609405 [details] patch for webapps.js Currently if you call uninstall on an app that is no longer installed, the onerror handler is invoked as expected but the error message is the origin ? this is something that would be hard to script around, my recommendation would be to return a string indicating that the app was not able to be uninstalled.
Currently the HTML / JS implementation returns NOT_INSTALLED... which is interesting because that was the reason we were calling uninstall.. maybe something like UNABLE_TO_FIND_APP would be more useful
NOT_INSTALLED is the error message Fabrice and I discussed on IRC.
Yes, NOT_INSTALLED makes more sense. You just can't uninstall something that's not installed ;)
Created attachment 632109 [details] [diff] [review] Fix for bug, test, and fix for test This just ignores the message data sent from Webapps.jsm to Webapps.js (and turns all uninstall errors to NOT_INSTALLED), which seems to happen elsewhere in the codebase, but seems a little fishy. Maybe it should send the error name as the data.
Comment on attachment 632109 [details] [diff] [review] Fix for bug, test, and fix for test https://hg.mozilla.org/integration/mozilla-inbound/rev/5fb04d9a0ace