diff --git a/app/assets/javascripts/blacklists.js b/app/assets/javascripts/blacklists.js index f878464ee..14f1faad5 100644 --- a/app/assets/javascripts/blacklists.js +++ b/app/assets/javascripts/blacklists.js @@ -147,7 +147,11 @@ var tags = String($post.attr("data-tags")).match(/\S+/g) || []; tags = tags.concat(String($post.attr("data-pools")).match(/\S+/g) || []); tags.push("rating:" + $post.data("rating")); - // tags.push("user:" + $post.attr("data-uploader").toLowerCase()); + if ($post.attr("data-uploader")) { + tags.push("user:" + $post.attr("data-uploader").toLowerCase()); + } + tags.push("uploaderid:" + $post.attr("data-uploader-id")); + tags.push("toptaggerid:" + $post.attr("data-top-tagger")); $.each(String($post.data("flags")).match(/\S+/g) || [], function(i, v) { tags.push("status:" + v); }); diff --git a/app/presenters/post_presenter.rb b/app/presenters/post_presenter.rb index 4d72d2517..f8f97df88 100644 --- a/app/presenters/post_presenter.rb +++ b/app/presenters/post_presenter.rb @@ -98,6 +98,8 @@ class PostPresenter < Presenter data-pixiv-id="#{post.pixiv_id}" data-file-ext="#{post.file_ext}" data-source="#{h(post.source)}" + data-top-tagger="#{post.keeper_id}" + data-uploader-id="#{post.uploader_id}" data-normalized-source="#{h(post.normalized_source)}" data-is-favorited="#{post.favorited_by?(CurrentUser.user.id)}" }