Skip to content

CORS pre-fetch not respecting per-route config #2491

Description

@jgauna

I've been using HapiJs for some weeks and it's really great but I can't make it work with CORS. Right now I have method (POST) with:

        cors: {
            origin: ['*']
        },

And it's working great. I've added a new one (PUT) and it's not working:

XMLHttpRequest cannot load http://192.168.0.21:3000/updateOrder.... No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost' is therefore not allowed access. The response had HTTP status code 404

Also, I've opened this issue days ago in StackOverflow and didn't get any answer:

http://stackoverflow.com/questions/29424735/cant-use-authorization-in-hapi-js

Any ideas guys?

Thanks in advance

Metadata

Metadata

Assignees

Labels

breaking changesChange that can breaking existing codebugBug or defectsecurityIssue with security impact

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions