Merge pull request #281 from shikorism/fix/279-unauthorized-ajax-call

非ログイン状態でいいねしようとした時にログインを促す
This commit is contained in:
shibafu authored and GitHub committed 2019-10-11 00:31:24 +09:00
commit 7b8811b894
1 file changed
+4 -1
+4 -1
View File
@@ -85,6 +85,9 @@ $(() => {
if (xhr.status === 409) {
callback(JSON.parse(xhr.responseText));
return;
} else if (xhr.status === 401) {
alert('いいねするためにはログインしてください。');
return;
}
console.error(xhr);
@@ -98,4 +101,4 @@ $(() => {
$this.siblings(".card-link").removeClass("card-spoiler");
$this.remove();
});
});
});