mirror of
https://github.com/bulwarkmail/native.git
synced 2026-11-01 00:07:01 +00:00
The contacts planner read RAW_CONTACT_IS_READ_ONLY with every raw contact, but ContactsProvider takes that column only on writes: every projection and selection that names it fails with "Invalid column", on API 32 and API 35 alike. Every contacts sync on a device therefore failed before it wrote a row. The fake provider accepted the column, so no test noticed. The flag is now only written, along with any raw contact write that happens anyway, so echoes stay write-free. Whether a contact's device edits are put back is decided from the server's current rights on the card, which is also right when only the rights changed. The fake now refuses the column in queries and selections like the real providers, and every other column the planners query was checked against the real providers on both emulators. Checked: the contacts, engine and fake provider tests, `npm run typecheck` and `npm test` on this commit, and a contacts sync of usera on the API 32 emulator, which now completes.