|
|
@ -414,7 +414,6 @@
|
|
|
|
const regionCode = storage.get('regionCode');
|
|
|
|
const regionCode = storage.get('regionCode');
|
|
|
|
|
|
|
|
|
|
|
|
const contactModel = this.findContact(phoneNumber);
|
|
|
|
const contactModel = this.findContact(phoneNumber);
|
|
|
|
const color = contactModel ? contactModel.getColor() : null;
|
|
|
|
|
|
|
|
let profileName;
|
|
|
|
let profileName;
|
|
|
|
if (phoneNumber === window.storage.get('primaryDevicePubKey')) {
|
|
|
|
if (phoneNumber === window.storage.get('primaryDevicePubKey')) {
|
|
|
|
profileName = i18n('you');
|
|
|
|
profileName = i18n('you');
|
|
|
@ -426,7 +425,7 @@
|
|
|
|
phoneNumber: format(phoneNumber, {
|
|
|
|
phoneNumber: format(phoneNumber, {
|
|
|
|
ourRegionCode: regionCode,
|
|
|
|
ourRegionCode: regionCode,
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
color,
|
|
|
|
color: null,
|
|
|
|
avatarPath: contactModel ? contactModel.getAvatarPath() : null,
|
|
|
|
avatarPath: contactModel ? contactModel.getAvatarPath() : null,
|
|
|
|
name: contactModel ? contactModel.getName() : null,
|
|
|
|
name: contactModel ? contactModel.getName() : null,
|
|
|
|
profileName,
|
|
|
|
profileName,
|
|
|
@ -565,7 +564,6 @@
|
|
|
|
const contact = this.findAndFormatContact(phoneNumber);
|
|
|
|
const contact = this.findAndFormatContact(phoneNumber);
|
|
|
|
const contactModel = this.findContact(phoneNumber);
|
|
|
|
const contactModel = this.findContact(phoneNumber);
|
|
|
|
|
|
|
|
|
|
|
|
const authorColor = contactModel ? contactModel.getColor() : null;
|
|
|
|
|
|
|
|
const authorAvatarPath = contactModel
|
|
|
|
const authorAvatarPath = contactModel
|
|
|
|
? contactModel.getAvatarPath()
|
|
|
|
? contactModel.getAvatarPath()
|
|
|
|
: null;
|
|
|
|
: null;
|
|
|
@ -599,7 +597,6 @@
|
|
|
|
serverTimestamp: this.get('serverTimestamp'),
|
|
|
|
serverTimestamp: this.get('serverTimestamp'),
|
|
|
|
status: this.getMessagePropStatus(),
|
|
|
|
status: this.getMessagePropStatus(),
|
|
|
|
contact: this.getPropsForEmbeddedContact(),
|
|
|
|
contact: this.getPropsForEmbeddedContact(),
|
|
|
|
authorColor,
|
|
|
|
|
|
|
|
authorName: contact.name,
|
|
|
|
authorName: contact.name,
|
|
|
|
authorProfileName: contact.profileName,
|
|
|
|
authorProfileName: contact.profileName,
|
|
|
|
authorPhoneNumber: contact.phoneNumber,
|
|
|
|
authorPhoneNumber: contact.phoneNumber,
|
|
|
@ -764,7 +761,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
const { author, id, referencedMessageNotFound } = quote;
|
|
|
|
const { author, id, referencedMessageNotFound } = quote;
|
|
|
|
const contact = author && ConversationController.get(author);
|
|
|
|
const contact = author && ConversationController.get(author);
|
|
|
|
const authorColor = contact ? contact.getColor() : 'grey';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const authorPhoneNumber = format(author, {
|
|
|
|
const authorPhoneNumber = format(author, {
|
|
|
|
ourRegionCode: regionCode,
|
|
|
|
ourRegionCode: regionCode,
|
|
|
@ -794,7 +790,6 @@
|
|
|
|
authorPhoneNumber,
|
|
|
|
authorPhoneNumber,
|
|
|
|
authorProfileName,
|
|
|
|
authorProfileName,
|
|
|
|
authorName,
|
|
|
|
authorName,
|
|
|
|
authorColor,
|
|
|
|
|
|
|
|
onClick,
|
|
|
|
onClick,
|
|
|
|
referencedMessageNotFound,
|
|
|
|
referencedMessageNotFound,
|
|
|
|
};
|
|
|
|
};
|
|
|
|