Implement Resource Item Not Found
This commit is contained in:
1 parent
c9a9e90a7e
commit
0535f66c85
2 files changed
+4
-1
No files matched your search
@@ -185,6 +185,8 @@ async def get_field(request):
|
||||
content = await connection.get(field)
|
||||
except ValueError:
|
||||
return web.Response(status=400, reason="Invalid Resource Path")
|
||||
except KeyError:
|
||||
return web.Response(status=204, reason="Resource Item Not Found")
|
||||
|
||||
if isinstance(content, StreamReader):
|
||||
response = web.StreamResponse(status=200, reason="OK")
|
||||
|
||||
Reference in new issue
Block a user