summaryrefslogtreecommitdiff
path: root/internal/gtsmodel/mention.go
diff options
context:
space:
mode:
authorLibravatar Tobi Smethurst <31960611+tsmethurst@users.noreply.github.com>2021-05-15 11:58:11 +0200
committerLibravatar GitHub <noreply@github.com>2021-05-15 11:58:11 +0200
commitcc48294c31a76e94fa879ad0d8d5dbd7e94c651b (patch)
tree7c26d33b41bab33bbdfbba540958444f4c296602 /internal/gtsmodel/mention.go
parentMediahandler (#21) (diff)
downloadgotosocial-cc48294c31a76e94fa879ad0d8d5dbd7e94c651b.tar.xz
Inbox post (#22)
Inbox POST from federated servers now working for statuses and follow requests. Follow request client API added. Start work on federating outgoing messages. Other fixes and changes/tidying up.
Diffstat (limited to 'internal/gtsmodel/mention.go')
-rw-r--r--internal/gtsmodel/mention.go16
1 files changed, 14 insertions, 2 deletions
diff --git a/internal/gtsmodel/mention.go b/internal/gtsmodel/mention.go
index 18eb11082..8e56a1b36 100644
--- a/internal/gtsmodel/mention.go
+++ b/internal/gtsmodel/mention.go
@@ -30,10 +30,22 @@ type Mention struct {
CreatedAt time.Time `pg:"type:timestamp,notnull,default:now()"`
// When was this mention last updated?
UpdatedAt time.Time `pg:"type:timestamp,notnull,default:now()"`
- // Who created this mention?
+ // What's the internal account ID of the originator of the mention?
OriginAccountID string `pg:",notnull"`
- // Who does this mention target?
+ // What's the AP URI of the originator of the mention?
+ OriginAccountURI string `pg:",notnull"`
+ // What's the internal account ID of the mention target?
TargetAccountID string `pg:",notnull"`
// Prevent this mention from generating a notification?
Silent bool
+ // NameString is for putting in the namestring of the mentioned user
+ // before the mention is dereferenced. Should be in a form along the lines of:
+ // @whatever_username@example.org
+ //
+ // This will not be put in the database, it's just for convenience.
+ NameString string `pg:"-"`
+ // MentionedAccountURI is the AP ID (uri) of the user mentioned.
+ //
+ // This will not be put in the database, it's just for convenience.
+ MentionedAccountURI string `pg:"-"`
}