From 4628f507e5209b560813578e86ebdc1ca747eda3 Mon Sep 17 00:00:00 2001 From: Satsuki Yanagi <17376330+u1-liquid@users.noreply.github.com> Date: Sun, 7 Jul 2019 17:14:08 +0900 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E9=96=8B=E4=BB=A5=E5=A4=96=E3=81=B8?= =?UTF-8?q?=E3=81=AE=E3=83=AA=E3=83=97=E3=83=A9=E3=82=A4=E6=99=82=E5=85=83?= =?UTF-8?q?=E3=81=AE=E5=85=AC=E9=96=8B=E7=AF=84=E5=9B=B2=E3=81=A7=E6=8C=87?= =?UTF-8?q?=E5=AE=9A=E3=81=97=E3=81=9F=E3=83=A6=E3=83=BC=E3=82=B6=E3=83=BC?= =?UTF-8?q?=E6=83=85=E5=A0=B1=E3=82=92=E5=BC=95=E3=81=8D=E7=B6=99=E3=81=90?= =?UTF-8?q?=E3=82=88=E3=81=86=E3=81=AB=20(#5119)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 公開以外へのリプライ時元の公開範囲で指定したユーザー情報を引き継ぐように * Use users/show userIds --- src/client/app/common/scripts/post-form.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/client/app/common/scripts/post-form.ts b/src/client/app/common/scripts/post-form.ts index 85a578484..7cd2e7c31 100644 --- a/src/client/app/common/scripts/post-form.ts +++ b/src/client/app/common/scripts/post-form.ts @@ -151,9 +151,16 @@ export default (opts) => ({ // 公開以外へのリプライ時は元の公開範囲を引き継ぐ if (this.reply && ['home', 'followers', 'specified'].includes(this.reply.visibility)) { this.visibility = this.reply.visibility; + if (this.reply.visibility === 'specified') { + this.$root.api('users/show', { + userIds: this.reply.visibleUserIds.filter(uid => uid !== this.$store.state.i.id && uid !== this.reply.userId) + }).then(users => { + this.visibleUsers.push(...users); + }); + } } - if (this.reply) { + if (this.reply && this.reply.userId !== this.$store.state.i.id) { this.$root.api('users/show', { userId: this.reply.userId }).then(user => { this.visibleUsers.push(user); });