Skip to content

Commit

Permalink
A empty string id is not useful, and trips up the auto assignment of …
Browse files Browse the repository at this point in the history
…an id.
  • Loading branch information
kriszyp committed Oct 11, 2013
1 parent 7fb167c commit 0bb4b45
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion jsgi/rest-store.js
Expand Up @@ -73,7 +73,9 @@ exports.RestStore = function(options){
};
}
}
metadata.id = decodeURIComponent(path);
if(path){
metadata.id = decodeURIComponent(path);
}

if(!METHOD_HAS_BODY[method]){
if(method === "get" && (!path || path.charAt(path.length-1) == '/')){
Expand Down

0 comments on commit 0bb4b45

Please sign in to comment.