diff --git a/app/components/post_preview_component.rb b/app/components/post_preview_component.rb index e1e955368..bac9bdfb3 100644 --- a/app/components/post_preview_component.rb +++ b/app/components/post_preview_component.rb @@ -95,7 +95,6 @@ class PostPreviewComponent < ApplicationComponent "data-parent-id" => post.parent_id, "data-has-children" => post.has_children?, "data-score" => post.score, - "data-views" => post.view_count, "data-fav-count" => post.fav_count, "data-pixiv-id" => post.pixiv_id, "data-file-ext" => post.file_ext, diff --git a/app/models/post.rb b/app/models/post.rb index 084740041..8ace11420 100644 --- a/app/models/post.rb +++ b/app/models/post.rb @@ -58,7 +58,7 @@ class Post < ApplicationRecord has_many :favorited_users, through: :favorites, source: :user has_many :replacements, class_name: "PostReplacement", :dependent => :destroy - attr_accessor :old_tag_string, :old_parent_id, :old_source, :old_rating, :has_constraints, :disable_versioning, :view_count + attr_accessor :old_tag_string, :old_parent_id, :old_source, :old_rating, :has_constraints, :disable_versioning scope :pending, -> { where(is_pending: true) } scope :flagged, -> { where(is_flagged: true) }