You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Community chats are cached as groups without an access hash #45
Found while fixing #18. mtcute 0.32 has community and communityForbidden chats. They have channel IDs and need an access hash, like channels, but the chat cache treats them as basic groups:
rawChatType and getChatType (src/commands/chats/helpers.ts) store their type as group.
rawChatToCacheInput and dialogToCacheInput keep the access hash only for channel and channelForbidden, so a community row has access_hash = NULL and its sync jobs build inputPeerChannel with hash 0.
Since #18 the row's ID is right (-100…, from the raw peer), so only the type and the hash are wrong.
Fix: give communities their own handling: keep the access hash, and either a community type or the closest existing one, documented in docs/database-schema.md.
Done when unit tests show a community from a dialog and from a raw chat cached with its access hash and a type that tg chats list --type can filter on, and buildInputPeer builds its peer with that hash.
Activity
docs: add the changelog entries for the 0.4.0 bug fixes