Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

$resource shouldn't collapse URL to "" #5455

Closed
sma opened this issue Dec 17, 2013 · 0 comments
Closed

$resource shouldn't collapse URL to "" #5455

sma opened this issue Dec 17, 2013 · 0 comments

Comments

@sma
Copy link

sma commented Dec 17, 2013

Consider this $resource definition:

$resource('/:collection/:id');

I can successfully query /foo/1 and /foo however, I'd also like to query / if there is neither a collection or an id passed to query(). Unfortunately, the URL is collapsed to "" instead of "/", probably in an attempt to remove a trailing slash.

@ghost ghost assigned jeffbcross Dec 17, 2013
gsklee pushed a commit to gsklee/angular.js that referenced this issue Dec 20, 2013
jamesdaily pushed a commit to jamesdaily/angular.js that referenced this issue Jan 27, 2014
…ring

if url template would result in an empty string, we should make a request
to '/' instead.

Closes angular#5455
Closes angular#5493
jamesdaily pushed a commit to jamesdaily/angular.js that referenced this issue Jan 27, 2014
…ring

if url template would result in an empty string, we should make a request
to '/' instead.

Closes angular#5455
Closes angular#5493
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants