Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions ts/receiver/queuedJob.ts
Original file line number Diff line number Diff line change
Expand Up @@ -304,11 +304,13 @@ async function handleRegularMessage(

handleLinkPreviews(rawDataMessage.body, rawDataMessage.preview, message);

// TODO: add pro status check for sender
const isSenderPro = false;
const maxChars = isSenderPro
? Constants.CONVERSATION.MAX_MESSAGE_CHAR_COUNT_PRO
: Constants.CONVERSATION.MAX_MESSAGE_CHAR_COUNT_STANDARD;
// TODO: Once pro proof validation is available make this dynamic
// const maxChars = isSenderPro
// ? Constants.CONVERSATION.MAX_MESSAGE_CHAR_COUNT_PRO
// : Constants.CONVERSATION.MAX_MESSAGE_CHAR_COUNT_STANDARD;
// NOTE: The truncation value must be the Pro count so when Pro is released older clients wont truncate pro messages.
const maxChars = Constants.CONVERSATION.MAX_MESSAGE_CHAR_COUNT_PRO;

const body =
rawDataMessage.body.length > maxChars
? rawDataMessage.body.slice(0, maxChars)
Expand Down