Skip to content

Commit

Permalink
nit, re #9968
Browse files Browse the repository at this point in the history
  • Loading branch information
apeters committed Aug 29, 2023
1 parent 678b124 commit 491ba7e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arches/app/views/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ def put(self, request, resourceid, slug=None, graphid=None):
if format not in allowed_formats:
return JSONResponse(status=406, reason="incorrect format specified, only %s formats allowed" % allowed_formats)

if format = "json-ld" and slug is None and graphid is None:
if format == "json-ld" and slug is None and graphid is None:
return JSONResponse({"error": "Need to supply either a graph id or slug in the request url. See the API reference in the developer documentation at https://arches.readthedocs.io for more details"}, status=400)

if not user_can_edit_resource(user=request.user, resourceid=resourceid):
Expand Down Expand Up @@ -632,7 +632,7 @@ def post(self, request, resourceid=None, slug=None, graphid=None):
if format not in allowed_formats:
return JSONResponse(status=406, reason="incorrect format specified, only %s formats allowed" % allowed_formats)

if format = "json-ld" and slug is None and graphid is None:
if format == "json-ld" and slug is None and graphid is None:
return JSONResponse({"error": "Need to supply either a graph id or slug in the request url. See the API reference in the developer documentation at https://arches.readthedocs.io for more details"}, status=400)

try:
Expand Down

0 comments on commit 491ba7e

Please sign in to comment.