news updates: fix news updates not staying hidden.

ref: https://danbooru.donmai.us/forum_posts/151011

Bug: `Cookie.get("news-ticker") === key` always returned false because
the cookie was a string but the key was an integer.

Regressed in f72b32b27b after switching from `==` to `===`.
This commit is contained in:
evazion
2018-10-02 13:28:41 -05:00
parent d727e0e34c
commit 4fd949ca8d

View File

@@ -3,7 +3,7 @@ import Cookie from './cookie'
let NewsUpdate = {};
NewsUpdate.initialize = function() {
var key = $("#news-updates").data("id");
var key = $("#news-updates").data("id").toString();
if (Cookie.get("news-ticker") === key) {
$("#news-updates").hide();