I have a $resource that defines a custom url for the :all method.
angular.module('MyApp').
factory('Object', ['$resource', ($resource) ->
$resource(
'/api/groups/:group_id/objects/:id.json',
{
id: '@id',
group_id: '@group_id'
},
all: {
method: 'GET',
url: '/api/objects/all.json'
}
)
])
When my page loads, the request goes out to '/api/objects/all.json?'. It's loading correctly, but the presence of the ? is confusing to me. I didn't pass it any parameters, so why does angular add the ? to the request?
Can I get rid of it somehow?