window.log.info('updateExpireTimer() This is an outdated disappearing message setting');
window.log.info('WIP: updateExpireTimer() This is an outdated disappearing message setting');
return;
}
// NOTE: We don' mind if the message is the same, we still want to update the conversation because we want to show visible control messages we receive an ExpirationTimerUpdate
@ -929,6 +934,9 @@ export class ConversationModel extends Backbone.Model<ConversationAttributes> {
// if change was made remotely, don't send it to the contact/group
if(receivedAt||fromSync||fromConfigMessage){
window.log.debug(
`WIP: updateExpireTimer() Not sending an ExpireTimerUpdate message because the change was made remotely receivedAt:${receivedAt} fromSync:${fromSync} fromConfigMessage:${fromConfigMessage}`
);
return;
}
@ -942,13 +950,17 @@ export class ConversationModel extends Backbone.Model<ConversationAttributes> {
if(this.isMe()){
// TODO Check that the args are correct
// This might be happening too late in the message pipeline. Maybe should be moved to handleExpirationTimerUpdateNoCommit()
// NOTE: if you do any changes to the settings of a user which are synced, it should be done above the `updateOurProfileLegacyOrViaLibSession` call
awaitupdateOurProfileLegacyOrViaLibSession(
result.latestEnvelopeTimestamp,
updateUserInfo.name,
picUpdate?updateUserInfo.url : null,
picUpdate?updateUserInfo.key : null,
updateUserInfo.priority
);
// NOTE: if you do any changes to the user's settings which are synced, it should be done above the `updateOurProfileLegacyOrViaLibSession` call
awaitupdateOurProfileLegacyOrViaLibSession({
sentAt: result.latestEnvelopeTimestamp,
displayName: updateUserInfo.name,
profileUrl: picUpdate?updateUserInfo.url : null,
profileKey: picUpdate?updateUserInfo.key : null,
priority: updateUserInfo.priority,
});
// NOTE: If we want to update the conversation in memory with changes from the updated user profile we need to wait untl the profile has been updated to prevent multiple merge conflicts
// make sure to write the changes to the database now as the `AvatarDownloadJob` triggered by updateOurProfileLegacyOrViaLibSession might take some time before getting run