track reply-tile

This commit is contained in:
RMidhunSuresh 2022-01-13 20:13:00 +05:30
parent a77b9d9027
commit 58dd25b58d

View File

@ -121,6 +121,7 @@ export class BaseMessageTile extends SimpleTile {
// this is an update to contextEntry used for replyPreview // this is an update to contextEntry used for replyPreview
const action = this._replyTile?.updateEntry(replyEntry); const action = this._replyTile?.updateEntry(replyEntry);
if (action?.shouldReplace) { if (action?.shouldReplace) {
this.disposeTracked(this._replyTile);
this._replyTile = this._tileCreator(replyEntry); this._replyTile = this._tileCreator(replyEntry);
} }
else { else {
@ -234,7 +235,7 @@ export class BaseMessageTile extends SimpleTile {
if (!this._replyTile) { if (!this._replyTile) {
const entry = this._entry.contextEntry; const entry = this._entry.contextEntry;
if (entry) { if (entry) {
this._replyTile = this._tileCreator(entry); this._replyTile = this.track(this._tileCreator(entry));
} }
} }
return this._replyTile; return this._replyTile;