Validate hosted app URL before adding

VERIFIED FIXED in Firefox 26

Status

defect
P1
normal
VERIFIED FIXED
6 years ago
Last year

People

(Reporter: jryans, Assigned: paul)

Tracking

Trunk
Firefox 27

Firefox Tracking Flags

(firefox26 verified, firefox27 verified, b2g-v1.2 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

Currently you can "add" a hosted app without entering a URL.  You then end up with a broken app that cannot select or remove in the project list.
Priority: -- → P1
Actually, it's even worse, as it seems to make the entire list of projects unusable once you close and re-open the App Manager after doing this.
There might be 2 bugs here:
1) template or store issue (invalid data should not break the UI)
2) the (+) button should act the same way as the form (with validation)
Assignee: nobody → paul
Posted patch Patch V1 (obsolete) — Splinter Review
Attachment #814810 - Flags: review?(poirot.alex)
Whiteboard: [needed-in-aurora-26]
Whiteboard: [needed-in-aurora-26] → [needed-in-aurora-26][waiting-for-review]
Comment on attachment 814810 [details] [diff] [review]
Patch V1

Review of attachment 814810 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good!

::: browser/devtools/app-manager/app-projects.js
@@ +62,5 @@
>      let deferred = promise.defer();
>  
> +    if (!project.location) {
> +      // We need to make sure this object has a `.location` property.
> +      deferred.reject("No location property");

I'd have been more explicit with the error message.
Like "Missing location property on project object."
Attachment #814810 - Flags: review?(poirot.alex) → review+
Posted patch Patch to landSplinter Review
Keywords: checkin-needed
Whiteboard: [needed-in-aurora-26][waiting-for-review] → [needed-in-aurora-26][land-in-fx-team]
Attachment #814810 - Attachment is obsolete: true
https://hg.mozilla.org/integration/fx-team/rev/bfd211789733
Keywords: checkin-needed
Whiteboard: [needed-in-aurora-26][land-in-fx-team] → [needed-in-aurora-26][fixed-in-fx-team]
https://hg.mozilla.org/mozilla-central/rev/bfd211789733
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Whiteboard: [needed-in-aurora-26][fixed-in-fx-team] → [needed-in-aurora-26]
Target Milestone: --- → Firefox 27
Comment on attachment 814843 [details] [diff] [review]
Patch to land

[Approval Request Comment]
Bug caused by (feature/regressing bug #): new feature (app manager)
User impact if declined: Can break his project list
Testing completed (on m-c, etc.): fx-team
Risk to taking this patch (and alternatives if risky): low
String or IDL/UUID changes made by this patch: none
Attachment #814843 - Flags: approval-mozilla-aurora?
Whiteboard: [needed-in-aurora-26] → [waiting-for-aurora-approval]
Attachment #814843 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Keywords: verifyme
Verified as fixed on latest Aurora 27.0a2 (20131112004004) and Firefox 26 beta 4 (20131111154639) using Win 7 64-bit, Ubuntu 13.04 32-bit and Mac OS X 10.6.8.
QA Contact: petruta.rasa
Status: RESOLVED → VERIFIED
Keywords: verifyme
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.