all: add support for topics and refactor other things
This commit is contained in:
@@ -50,6 +50,7 @@ type GhostMetadata struct {
|
||||
|
||||
type PortalMetadata struct {
|
||||
IsSuperGroup bool `json:"is_supergroup,omitempty"`
|
||||
IsForumGeneral bool `json:"is_forum_general,omitempty"`
|
||||
ReadUpTo int `json:"read_up_to,omitempty"`
|
||||
AllowedReactions []string `json:"allowed_reactions"`
|
||||
LastSync jsontime.Unix `json:"last_sync,omitempty"`
|
||||
@@ -63,6 +64,12 @@ func (pm *PortalMetadata) SetIsSuperGroup(isSupergroup bool) (changed bool) {
|
||||
return changed
|
||||
}
|
||||
|
||||
func (pm *PortalMetadata) SetIsForumGeneral(isForumGeneral bool) (changed bool) {
|
||||
changed = pm.IsForumGeneral != isForumGeneral
|
||||
pm.IsForumGeneral = isForumGeneral
|
||||
return changed
|
||||
}
|
||||
|
||||
type MessageMetadata struct {
|
||||
ContentHash []byte `json:"content_hash,omitempty"`
|
||||
ContentURI id.ContentURIString `json:"content_uri,omitempty"`
|
||||
|
||||
Reference in New Issue
Block a user