mirror of
https://github.com/jupyter/notebook.git
synced 2024-12-09 03:50:45 +08:00
Fix handling of preflight requests
Pre-flighted OPTIONS requests do not include authentication information, which means that we should not expect these to be authenticated. Authentication will be validated when the real PUT/POST etc request is issued after the preflight.
This commit is contained in:
parent
6b220c949b
commit
4a161fea12
@ -387,7 +387,6 @@ class APIHandler(IPythonHandler):
|
||||
self.set_header('Content-Type', 'application/json')
|
||||
return super(APIHandler, self).finish(*args, **kwargs)
|
||||
|
||||
@web.authenticated
|
||||
def options(self, *args, **kwargs):
|
||||
self.set_header('Access-Control-Allow-Headers', 'accept, content-type')
|
||||
self.set_header('Access-Control-Allow-Methods',
|
||||
|
Loading…
Reference in New Issue
Block a user