From f9fe84914ac9f0a05897908c8da94ea940991d36 Mon Sep 17 00:00:00 2001 From: Z Date: Thu, 7 Nov 2019 16:47:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8D=E5=9C=A8=E6=97=B6=E9=97=B4=E7=BA=BF?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E8=87=AA=E5=9B=9E=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/status.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/status.rb b/app/models/status.rb index a748e3297..00a302721 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -82,7 +82,8 @@ class Status < ApplicationRecord scope :remote, -> { where(local: false).where.not(uri: nil) } scope :local, -> { where(local: true).or(where(uri: nil)) } - scope :without_replies, -> { where('statuses.reply = FALSE OR statuses.in_reply_to_account_id = statuses.account_id') } + #scope :without_replies, -> { where('statuses.reply = FALSE OR statuses.in_reply_to_account_id = statuses.account_id') } + scope :without_replies, -> { where('statuses.reply = FALSE') } scope :without_reblogs, -> { where('statuses.reblog_of_id IS NULL') } scope :with_public_visibility, -> { where(visibility: :public) } scope :tagged_with, ->(tag) { joins(:statuses_tags).where(statuses_tags: { tag_id: tag }) }