Browse Source

Fix opening channel avatar

master
Eduard Kuzmenko 3 years ago
parent
commit
f7fd6832eb
  1. 4
      .env
  2. 7
      src/lib/appManagers/appMessagesManager.ts

4
.env

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
API_ID=1025907
API_HASH=452b0359b988148995f22ff0f4229750
VERSION=1.2.0
VERSION_FULL=1.2.0 (118)
BUILD=118
VERSION_FULL=1.2.0 (119)
BUILD=119

7
src/lib/appManagers/appMessagesManager.ts

@ -1635,17 +1635,20 @@ export class AppMessagesManager { @@ -1635,17 +1635,20 @@ export class AppMessagesManager {
public generateFakeAvatarMessage(peerId: PeerId, photo: Photo) {
const maxId = Number.MAX_SAFE_INTEGER;
const message = {
const message: Message.messageService = {
_: 'messageService',
pFlags: {},
action: {
_: 'messageActionChannelEditPhoto',
photo
},
id: maxId,
peer_id: appPeersManager.getOutputPeer(peerId),
mid: maxId,
peerId,
date: (photo as Photo.photo).date,
fromId: peerId
} as Message.messageService;
};
this.getMessagesStorage(peerId).set(maxId, message);
return message;

Loading…
Cancel
Save