Skip to content

Commit

Permalink
fix: don't return in /questions/unanswered reserved barcode by default
Browse files Browse the repository at this point in the history
To be consistent with other /questions/* endpoints
  • Loading branch information
raphael0202 committed Oct 12, 2022
1 parent 91ed2d2 commit 78af005
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions robotoff/app/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1173,6 +1173,9 @@ def on_get(self, req: falcon.Request, resp: falcon.Response):
value_tag: str = req.get_param("value_tag")
country: Optional[str] = req.get_param("country")
server_domain: Optional[str] = req.get_param("server_domain")
reserved_barcode: Optional[bool] = req.get_param_as_bool(
"reserved_barcode", default=False
)
campaign: Optional[str] = req.get_param("campaign")

get_insights_ = functools.partial(
Expand All @@ -1184,6 +1187,7 @@ def on_get(self, req: falcon.Request, resp: falcon.Response):
country=country,
server_domain=server_domain,
automatically_processable=False,
reserved_barcode=reserved_barcode,
campaign=campaign,
)

Expand Down

0 comments on commit 78af005

Please sign in to comment.