commit eabb9062686a38246ff7496270327cccc4b2f3fe
parent 6ebdc306edd9b1ee0d853bdad63c0fb418382eb7
Author: tobi <31960611+tsmethurst@users.noreply.github.com>
Date: Wed, 21 Dec 2022 17:52:07 +0100
[bugfix] fix media create error not being checked (#1283)
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/internal/api/client/media/mediacreate.go b/internal/api/client/media/mediacreate.go
@@ -124,7 +124,7 @@ func (m *Module) MediaCreatePOSTHandler(c *gin.Context) {
}
apiAttachment, errWithCode := m.processor.MediaCreate(c.Request.Context(), authed, form)
- if err != nil {
+ if errWithCode != nil {
api.ErrorHandler(c, errWithCode, m.processor.InstanceGet)
return
}