Expand description
Per-scope notification preferences: one row per community, channel or DM that deviates from the defaults. Absence of a row means “inherit everything”, so an untouched account stores nothing.
Functions§
- clear_
expired_ mutes - Clear the mute on scopes whose timer has run out, in one statement.
- live_
channel_ ids - Every channel id its community still lists. A tombstoned channel’s row is pruned here while its chat row and history stay on disk, so this is the difference between “belongs to a community” and “can still be opened”.
- load_
all - Every stored scope. The table holds only customised scopes, so this stays small enough to keep in memory rather than querying per lookup.
- replace_
all - Replace the whole table in one transaction, for a list arriving from another device. Whole-list newest-wins is the merge these projections use, so a partial apply would be a third state neither device holds.
- save
- Write one scope. A scope back at every default is deleted rather than stored, so the table never accumulates rows that say nothing.