Skip to content

Instantly share code, notes, and snippets.

@davidpp
Created July 31, 2013 11:58
Show Gist options
  • Select an option

  • Save davidpp/6121370 to your computer and use it in GitHub Desktop.

Select an option

Save davidpp/6121370 to your computer and use it in GitHub Desktop.
Example of a restangular POST not returning a response object
Restangular.all('devices').post(device_to_activate).then(function(response) {
$log.info("Device activated", response);
alert("Error " + response.status + ", " + response.data);
}, function(response) {
alert("Error " + response.status + ", " + response.data.message);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment