From bc667cc911c366a4a3543da5d3a915d29c7b2f6a Mon Sep 17 00:00:00 2001 From: Gursewak Singh Date: Thu, 27 Jun 2024 22:25:16 -0700 Subject: [PATCH] issue #5751. Fixed pinned messages showing editing history --- app/lib/services/restApi.ts | 2 +- app/views/MessagesView/index.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/lib/services/restApi.ts b/app/lib/services/restApi.ts index ce42c92986..deb871b8dd 100644 --- a/app/lib/services/restApi.ts +++ b/app/lib/services/restApi.ts @@ -678,7 +678,7 @@ export const getFiles = (roomId: string, type: SubscriptionType, offset: number) export const getMessages = ( roomId: string, type: SubscriptionType, - query: { 'mentions._id': { $in: string[] } } | { 'starred._id': { $in: string[] } } | { pinned: boolean }, + query: { 'mentions._id': { $in: string[] } } | { 'starred._id': { $in: string[] } } | { pinned: boolean, _hidden: {$ne: boolean}}, offset: number ) => { const t = type as SubscriptionType.DIRECT | SubscriptionType.CHANNEL | SubscriptionType.GROUP; diff --git a/app/views/MessagesView/index.tsx b/app/views/MessagesView/index.tsx index e080c61b46..c83e3d2d11 100644 --- a/app/views/MessagesView/index.tsx +++ b/app/views/MessagesView/index.tsx @@ -248,7 +248,7 @@ class MessagesView extends React.Component { const { messages } = this.state; - return Services.getMessages(this.rid, this.t, { pinned: true }, messages.length); + return Services.getMessages(this.rid, this.t, { pinned: true, _hidden: {$ne: true}}, messages.length); }, noDataMsg: I18n.t('No_pinned_messages'), testID: 'pinned-messages-view',