Page MenuHomePhabricator

[lib] check timestamps before processing edit entry operation
ClosedPublic

Authored by will on Sep 16 2024, 1:31 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 2, 4:32 AM
Unknown Object (File)
Sat, Nov 2, 4:32 AM
Unknown Object (File)
Sat, Nov 2, 4:32 AM
Unknown Object (File)
Sat, Nov 2, 4:32 AM
Unknown Object (File)
Sat, Nov 2, 4:31 AM
Unknown Object (File)
Wed, Oct 23, 9:12 AM
Unknown Object (File)
Tue, Oct 22, 1:18 PM
Unknown Object (File)
Tue, Oct 22, 10:22 AM
Subscribers
None

Details

Summary

This checks the timestamp to ensure that an edit operation produces a no-op update if produced with a timestamp before latest updated time

Follows logic from https://phab.comm.dev/D13215

Depends on D13346

Test Plan

Not sure how to test this yet. Might manually run these with different timestamps? Unsure how I might be able to introduce a delay.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

will requested review of this revision.Sep 16 2024, 2:05 AM
tomek added inline comments.
lib/shared/dm-ops/edit-entry-spec.js
46 ↗(On Diff #44201)

It would be easier if we kept this property name consistent between all the operations.

66 ↗(On Diff #44201)

Can we early exit when this condition isn't met? We should return only rawMessageInfos with empty updateInfos in such a case.

This revision is now accepted and ready to land.Sep 16 2024, 5:46 AM

remove unnecesssary Thick thread type import