Skip to content

Commit

Permalink
Merge pull request #2380 from yougotwill/patch-2
Browse files Browse the repository at this point in the history
refactor: Removed duplicate check in Message getDescription()
  • Loading branch information
Bilb authored Jul 11, 2022
2 parents fd95d3a + 09dec12 commit e950074
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions ts/models/message.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1295,21 +1295,6 @@ export class MessageModel extends Backbone.Model<MessageAttributes> {
return window.i18n('answeredACall', [displayName]);
}
}
if (this.get('callNotificationType')) {
const displayName = getConversationController().getContactProfileNameOrShortenedPubKey(
this.get('conversationId')
);
const callNotificationType = this.get('callNotificationType');
if (callNotificationType === 'missed-call') {
return window.i18n('callMissed', [displayName]);
}
if (callNotificationType === 'started-call') {
return window.i18n('startedACall', [displayName]);
}
if (callNotificationType === 'answered-a-call') {
return window.i18n('answeredACall', [displayName]);
}
}
return this.get('body');
}
}
Expand Down

0 comments on commit e950074

Please sign in to comment.