Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Host does not resolve when the start of the path is the same string as the namespace. #430

@andrew-paterson

Description

@andrew-paterson

I'm using Ember 3.1.2, and ember-ajax 3.0.0.

Assuming I'm serving my Ember app at localhost:4200 and have the namespace and host configured as follows:

// services/ajax
namespace: '/foo',
host: `https://test.com`,

If I then call

this.get('ajax').request('/foobar/posts');

the host and namespace are not added to the request URL which becomes

localhost:4200/foobar/posts

where it should be

https://test.com/foo/foobar/posts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions