Skip to content

When Browser sends OPTIONS request cors=True has no effect #25

@steliospaps

Description

@steliospaps

This applies to when the lambda is handling the OPTIONS method, and running the lambda with sam local. (I have not tested elsewhere)

OPTIONS request:
`
curl -i 'http://localhost:3000/calendar_location/distances?date=2019-10-28' -X OPTIONS

HTTP/1.0 200 OK

Content-Length: 0

Server: Werkzeug/0.15.6 Python/3.7.4

Date: Sat, 09 Nov 2019 23:34:46 GMT
`

GET request:
`curl -i 'http://localhost:3000/calendar_location/distances?date=2019-10-28'

HTTP/1.0 200 OK

Content-Type: application/json

Access-Control-Allow-Origin: *

Access-Control-Allow-Methods: GET,OPTIONS

Access-Control-Allow-Credentials: true

Content-Length: 870

Server: Werkzeug/0.15.6 Python/3.7.4

Date: Sat, 09 Nov 2019 23:35:04 GMT

....
`

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions