API: Add return to preview error handler
Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
parent
ce5d124af8
commit
c7e46c44d9
1 changed files with 1 additions and 0 deletions
|
@ -86,6 +86,7 @@ func GetPreview(router *gin.RouterGroup, conf *config.Config) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Error(err)
|
log.Error(err)
|
||||||
c.Data(http.StatusNotFound, "image/svg+xml", photoIconSvg)
|
c.Data(http.StatusNotFound, "image/svg+xml", photoIconSvg)
|
||||||
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
preview = imaging.Paste(preview, src, image.Pt(x, y))
|
preview = imaging.Paste(preview, src, image.Pt(x, y))
|
||||||
|
|
Loading…
Reference in a new issue