Closed
Bug 886385
Opened 12 years ago
Closed 12 years ago
API returns "developed":true from search and "developed":false from app endpoint
Categories
(Marketplace Graveyard :: API, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
2013-06-27
People
(Reporter: basta, Assigned: robhudson)
Details
As a reviewer/admin, search for an app and visit the detail page. You'll see an Edit Listing button. Then refresh the page; the button is gone.
The first view gets the app object from the search API, the second gets it from the app API.
The response should be consistent between APIs.
| Assignee | ||
Comment 1•12 years ago
|
||
(In reply to Matt Basta [:basta] from comment #0)
> As a reviewer/admin, search for an app and visit the detail page. You'll see
> an Edit Listing button. Then refresh the page; the button is gone.
>
> The first view gets the app object from the search API, the second gets it
> from the app API.
>
> The response should be consistent between APIs.
Which one seems more correct?
The search uses this query:
'developed': AddonUser.objects.filter(
user=profile, role=amo.AUTHOR_ROLE_OWNER).exists(),
The app detail uses this query:
'developed': app.has_author(profile, [amo.AUTHOR_ROLE_OWNER]),
Assignee: nobody → robhudson.mozbugs
Target Milestone: --- → 2013-06-27
Comment 2•12 years ago
|
||
The former is more semantically correct. But the latter allows us to check for 'developed' instead of 'developed' or 'reviewer' or 'admin'.
I'm okay with the latter; Basta filed this bug so he probably has an opinion. (Even if he didn't file the bug, I'm sure he has an opinion ;))
Flags: needinfo?(mattbasta)
| Reporter | ||
Comment 3•12 years ago
|
||
The former looks like it would be faster, let's go with that.
Flags: needinfo?(mattbasta)
| Assignee | ||
Comment 4•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•