[bugfix] Use 'Image' instead of unrecognized 'Gif' type for media attachments (#801)

* Store gifs as Image type

* remove Gif attachment type, add Gifv type

* update test
This commit is contained in:
tobi 2022-09-04 14:58:58 +02:00 committed by GitHub
commit 2db0c64738
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 58 additions and 7 deletions

View file

@ -313,7 +313,7 @@ func (p *ProcessingMedia) store(ctx context.Context) error {
var clean io.Reader
switch extension {
case mimeGif:
p.attachment.Type = gtsmodel.FileTypeGif
p.attachment.Type = gtsmodel.FileTypeImage
clean = multiReader // nothing to clean from a gif
case mimeJpeg, mimePng:
p.attachment.Type = gtsmodel.FileTypeImage