diff options
author | 2021-06-13 18:42:28 +0200 | |
---|---|---|
committer | 2021-06-13 18:42:28 +0200 | |
commit | b4288f3c47a9ff9254b933dcb9ee7274d4a4135c (patch) | |
tree | 3fe1bb1ab8d4b8c5d9a83df708e5088f35c3150a /internal/gtsmodel/status.go | |
parent | Tidy + timeline embetterment (#38) (diff) | |
download | gotosocial-b4288f3c47a9ff9254b933dcb9ee7274d4a4135c.tar.xz |
Timeline manager (#40)
* start messing about with timeline manager
* i have no idea what i'm doing
* i continue to not know what i'm doing
* it's coming along
* bit more progress
* update timeline with new posts as they come in
* lint and fmt
* Select accounts where empty string
* restructure a bunch, get unfaves working
* moving stuff around
* federate status deletes properly
* mention regex better but not 100% there
* fix regex
* some more hacking away at the timeline code phew
* fix up some little things
* i can't even
* more timeline stuff
* move to ulid
* fiddley
* some lil fixes for kibou compatibility
* timelines working pretty alright!
* tidy + lint
Diffstat (limited to 'internal/gtsmodel/status.go')
-rw-r--r-- | internal/gtsmodel/status.go | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/internal/gtsmodel/status.go b/internal/gtsmodel/status.go index 16c00ca73..f5e332978 100644 --- a/internal/gtsmodel/status.go +++ b/internal/gtsmodel/status.go @@ -23,7 +23,7 @@ import "time" // Status represents a user-created 'post' or 'status' in the database, either remote or local type Status struct { // id of the status in the database - ID string `pg:"type:uuid,default:gen_random_uuid(),pk,notnull"` + ID string `pg:"type:CHAR(26),pk,notnull"` // uri at which this status is reachable URI string `pg:",unique"` // web url for viewing this status @@ -45,13 +45,13 @@ type Status struct { // is this status from a local account? Local bool // which account posted this status? - AccountID string + AccountID string `pg:"type:CHAR(26),notnull"` // id of the status this status is a reply to - InReplyToID string + InReplyToID string `pg:"type:CHAR(26)"` // id of the account that this status replies to - InReplyToAccountID string + InReplyToAccountID string `pg:"type:CHAR(26)"` // id of the status this status is a boost of - BoostOfID string + BoostOfID string `pg:"type:CHAR(26)"` // cw string for this status ContentWarning string // visibility entry for this status @@ -61,7 +61,7 @@ type Status struct { // what language is this status written in? Language string // Which application was used to create this status? - CreatedWithApplicationID string + CreatedWithApplicationID string `pg:"type:CHAR(26)"` // advanced visibility for this status VisibilityAdvanced *VisibilityAdvanced // What is the activitystreams type of this status? See: https://www.w3.org/TR/activitystreams-vocabulary/#object-types @@ -153,6 +153,7 @@ type VisibilityAdvanced struct { // RelevantAccounts denotes accounts that are replied to, boosted by, or mentioned in a status. type RelevantAccounts struct { + StatusAuthor *Account ReplyToAccount *Account BoostedAccount *Account BoostedReplyToAccount *Account |