mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-25 23:23:32 -06:00
[feature] Custom emoji updates (serve emoji via s2s api, tune db models) (#805)
* migrate emojis * add get emoji to s2s (federation) API * add new emoji db + cache functions * add shortcodeDomain lookup for emojis * check existing emojis w/cache, not w/constraints * go fmt * add putEmoji func * use new db emoji funcs instead of where * remove emojistringstotags func * add unique constraint back in * fix up broken migration * update index
This commit is contained in:
parent
ee01e030d4
commit
a872ddebe6
21 changed files with 773 additions and 62 deletions
|
|
@ -231,8 +231,8 @@ func (p *processor) getEmojiContent(ctx context.Context, wantedEmojiID string, e
|
|||
emojiContent := &apimodel.Content{}
|
||||
var storagePath string
|
||||
|
||||
e := >smodel.Emoji{}
|
||||
if err := p.db.GetByID(ctx, wantedEmojiID, e); err != nil {
|
||||
e, err := p.db.GetEmojiByID(ctx, wantedEmojiID)
|
||||
if err != nil {
|
||||
return nil, gtserror.NewErrorNotFound(fmt.Errorf("emoji %s could not be taken from the db: %s", wantedEmojiID, err))
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue