Redirect correctly after creating a bike

This commit is contained in:
Jason Denney
2014-03-09 22:48:59 -04:00
parent 64e907b6f7
commit b1ddcfb867
+1 -1
View File
@@ -21,7 +21,7 @@ $("#add_bike_submit").click(function(){
contentType: 'application/json',
dataType: "json",
success: function(data, status, xhr){
window.location = data.bikes[0].href;
window.location = data.bikes[0].id;
},
error: function(data, status ){
displayFormErrors(data.responseJSON);