Skip to content

Instantly share code, notes, and snippets.

@maxwell
Created February 23, 2011 06:16
Show Gist options
  • Save maxwell/840099 to your computer and use it in GitHub Desktop.
Save maxwell/840099 to your computer and use it in GitHub Desktop.
$(".new_status_message").bind('ajax:failure', function(data, html, xhr) {
json = $.parseJSON(html.response);
if(json.errors.length != 0){
Diaspora.widgets.alert.alert(json.errors);
}else{
Diaspora.widgets.alert.alert('Failed to post message!');
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment