Page MenuHomePhabricator

[lib][native] remove code duplication from `processDBStoreOperations`
ClosedPublic

Authored by kamil on Aug 19 2024, 5:39 AM.
Tags
None
Referenced Files
F3384592: D13107.diff
Thu, Nov 28, 9:43 PM
Unknown Object (File)
Fri, Nov 8, 7:03 PM
Unknown Object (File)
Fri, Nov 8, 7:03 PM
Unknown Object (File)
Fri, Nov 8, 7:01 PM
Unknown Object (File)
Fri, Nov 8, 1:42 AM
Unknown Object (File)
Sep 29 2024, 1:29 PM
Unknown Object (File)
Sep 29 2024, 1:22 PM
Unknown Object (File)
Sep 29 2024, 11:28 AM
Subscribers

Details

Summary

Cleaning this tp reduce code duplication and simplify logic

Test Plan

Play with app and make sure ops are processed and results are persisted.

Diff Detail

Repository
rCOMM Comm
Branch
enable-db-publish
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Aug 19 2024, 6:08 AM
tomek added inline comments.
web/database/sqlite-api.js
199

We were checking the drafts differently from the other ops. Are you sure the new logic is equivalent?

This revision is now accepted and ready to land.Aug 20 2024, 1:39 AM
web/database/sqlite-api.js
199

Yes, this line is different because drafts are not converted and can be nullable.

In the new code, this condition is inverted, we check if there is any field that exists and has a length higher than 0 so this should remain unchanged.