<% if @error %>
  Danbooru.notice("<%= j @error.to_s %>");
<% else %>
  Danbooru.notice("Unvoted successfully");
  $("#score-for-post-<%= @post.id %>").html(<%= @post.score %>);
<% end %>
$("#vote-links-for-post-<%= @post.id %>").show();
$("#unvote-link-for-post-<%= @post.id %>").hide();