Address more review comments

This commit is contained in:
Maxim Shishmarev 2019-11-25 12:02:03 +11:00
parent 56bb2ed792
commit 89e5e919f2
6 changed files with 10 additions and 9 deletions

View File

@ -2236,7 +2236,7 @@
"groupInvitation": {
"message": "Group Invitation"
},
"add-friends": {
"addingFriends": {
"message": "Adding friends to"
}
}

View File

@ -835,7 +835,7 @@
});
Whisper.events.on(
'invitationAccepted',
'publicChatInvitationAccepted',
async (serverAddress, channelId) => {
// To some degree this has been copy-pasted
// form connection_to_server_dialog_view.js:

View File

@ -1516,7 +1516,7 @@
}
const attributes = {
...messageWithSchema,
group_invitation: groupInvitation,
groupInvitation,
id: window.getGuid(),
};

View File

@ -267,7 +267,7 @@
return this.get('type') === 'friend-request';
},
isGroupInvitation() {
return !!this.get('group_invitation');
return !!this.get('groupInvitation');
},
getNotificationText() {
const description = this.getDescription();
@ -447,7 +447,7 @@
};
},
getPropsForGroupInvitation() {
const invitation = this.get('group_invitation');
const invitation = this.get('groupInvitation');
let direction = this.get('direction');
if (!direction) {
@ -460,7 +460,7 @@
direction,
onClick: () => {
Whisper.events.trigger(
'invitationAccepted',
'publicChatInvitationAccepted',
invitation.serverAddress,
invitation.channelId
);
@ -1938,6 +1938,7 @@
window.log.info(
`Starting handleDataMessage for message ${message.idForLogging()} in conversation ${conversation.idForLogging()}`
);
const withQuoteReference = await this.copyFromQuotedMessage(
initialMessage
);
@ -2021,7 +2022,7 @@
}
if (initialMessage.groupInvitation) {
message.set({ group_invitation: initialMessage.groupInvitation });
message.set({ groupInvitation: initialMessage.groupInvitation });
}
const urls = window.Signal.LinkPreviews.findLinks(dataMessage.body);

View File

@ -202,7 +202,7 @@ message DataMessage {
message GroupInvitation {
optional string serverAddress = 1;
optional string channelId = 2;
optional uint32 channelId = 2;
optional string serverName = 3;
}

View File

@ -55,7 +55,7 @@ export class InviteFriendsDialog extends React.Component<Props, State> {
}
public render() {
const titleText = `${window.i18n('add-friends')} ${this.props.chatName}`;
const titleText = `${window.i18n('addingFriends')} ${this.props.chatName}`;
const cancelText = window.i18n('cancel');
const okText = window.i18n('ok');