From eae9a4672c1a866964f37c3a77287df2311deae1 Mon Sep 17 00:00:00 2001 From: ychao_1983 Date: Wed, 29 Jun 2022 17:53:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=B5=B0=E6=9F=A5=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- models/attachment.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/attachment.go b/models/attachment.go index 913388670..8e8d42805 100755 --- a/models/attachment.go +++ b/models/attachment.go @@ -576,7 +576,7 @@ func AttachmentsByDatasetOption(datasets []int64, opts *SearchDatasetOptions) ([ cond = cond.And(builder.Gt{"attachment.decompress_state": 0}) } if opts.PublicOnly { - cond = cond.And(builder.Gt{"attachment.decompress_state": 0}) + cond = cond.And(builder.Eq{"attachment.is_private": false}) } if opts.CloudBrainType >= 0 { cond = cond.And(builder.Eq{"attachment.type": opts.CloudBrainType})