Skip to content

Commit

Permalink
chat: Only sign command args when profile keys defined (#1257)
Browse files Browse the repository at this point in the history
  • Loading branch information
evan-goode authored Dec 17, 2023
1 parent 827b6cd commit 0ac8c08
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/client/chat.js
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ module.exports = function (client, options) {
command,
timestamp: options.timestamp,
salt: options.salt,
argumentSignatures: signaturesForCommand(command, options.timestamp, options.salt, options.preview, acknowledgements),
argumentSignatures: client.profileKeys ? signaturesForCommand(command, options.timestamp, options.salt, options.preview, acknowledgements) : [],
messageCount: client._lastSeenMessages.pending,
acknowledged
})
Expand All @@ -381,7 +381,7 @@ module.exports = function (client, options) {
command,
timestamp: options.timestamp,
salt: options.salt,
argumentSignatures: signaturesForCommand(command, options.timestamp, options.salt),
argumentSignatures: client.profileKeys ? signaturesForCommand(command, options.timestamp, options.salt) : [],
signedPreview: options.didPreview,
previousMessages: client._lastSeenMessages.map((e) => ({
messageSender: e.sender,
Expand Down

0 comments on commit 0ac8c08

Please sign in to comment.