diff options
author | 2024-08-29 17:43:14 +0200 | |
---|---|---|
committer | 2024-08-29 17:43:14 +0200 | |
commit | e10aa76612bf20ca2a5aa8e7ee5e4d1aae0ba69f (patch) | |
tree | 593d7d2a166db86dc051f881688694e2c220e1fe /internal/api/client | |
parent | [chore] Update robots.txt with more AI scrapers (#3248) (diff) | |
download | gotosocial-e10aa76612bf20ca2a5aa8e7ee5e4d1aae0ba69f.tar.xz |
[chore] Only call `imaging.Resize when necessary`, use even tinier blurhashes (#3247)
* [chore] Use `imaging.Fit`, use even tinier blurhashes
* avoid calling resize if not necessary
* update blurhashes + thumb
Diffstat (limited to 'internal/api/client')
-rw-r--r-- | internal/api/client/instance/instancepatch_test.go | 2 | ||||
-rw-r--r-- | internal/api/client/media/mediacreate_test.go | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/internal/api/client/instance/instancepatch_test.go b/internal/api/client/instance/instancepatch_test.go index 5c5d59ef8..6148ed93e 100644 --- a/internal/api/client/instance/instancepatch_test.go +++ b/internal/api/client/instance/instancepatch_test.go @@ -858,7 +858,7 @@ func (suite *InstancePatchTestSuite) TestInstancePatch8() { "static_url": "http://localhost:8080/fileserver/01AY6P665V14JJR0AFVRT7311Y/attachment/small/`+instanceAccount.AvatarMediaAttachment.ID+`.webp",`+` "thumbnail_static_type": "image/webp", "thumbnail_description": "A bouncing little green peglin.", - "blurhash": "LE9as6M}4YtO%dRlWEt6Dmoxx?WC" + "blurhash": "LF9kG$RR4YtP%dR+V^t5D,oxx?WC" }`, string(instanceV2ThumbnailJson)) // double extra special bonus: now update the image description without changing the image diff --git a/internal/api/client/media/mediacreate_test.go b/internal/api/client/media/mediacreate_test.go index 7f8cc2d87..e7f98d6d7 100644 --- a/internal/api/client/media/mediacreate_test.go +++ b/internal/api/client/media/mediacreate_test.go @@ -206,7 +206,7 @@ func (suite *MediaCreateTestSuite) TestMediaCreateSuccessful() { Y: 0.5, }, }, *attachmentReply.Meta) - suite.Equal("LjCGfG#6RkRn_NvzRjWF?urqV@a$", *attachmentReply.Blurhash) + suite.Equal("LiBzRk#6V[WF_NvzV@WY_3rqV@a$", *attachmentReply.Blurhash) suite.NotEmpty(attachmentReply.ID) suite.NotEmpty(attachmentReply.URL) suite.NotEmpty(attachmentReply.PreviewURL) @@ -291,7 +291,7 @@ func (suite *MediaCreateTestSuite) TestMediaCreateSuccessfulV2() { Y: 0.5, }, }, *attachmentReply.Meta) - suite.Equal("LjCGfG#6RkRn_NvzRjWF?urqV@a$", *attachmentReply.Blurhash) + suite.Equal("LiBzRk#6V[WF_NvzV@WY_3rqV@a$", *attachmentReply.Blurhash) suite.NotEmpty(attachmentReply.ID) suite.Nil(attachmentReply.URL) suite.NotEmpty(attachmentReply.PreviewURL) |