Skip to content

Commit

Permalink
fix: if statement for alignment (#194)
Browse files Browse the repository at this point in the history
  • Loading branch information
LelouchFR authored Jul 27, 2024
1 parent c0a56e7 commit 896cf69
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ func generateSvg(iconNames []string, perLine int, hasTitlesEnabled bool, align s
`, scaledWidth, scaledHeight, length, height)
} else {
svg = fmt.Sprintf(`
<svg width="%d" height="%d" viewBox="0 0 %d %d" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1">
<svg width="%d" height="%d" viewBox="0 0 %d %d" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1">
`, scaledWidth, scaledHeight, length, height)
}

Expand Down Expand Up @@ -206,7 +206,7 @@ func iconRoute(r *gin.RouterGroup) {
}

align := ctx.Request.Form.Get("align")
if align == "" || align != "left" || align != "right" || align != "center" {
if align != "left" && align != "right" && align != "center" {
align = "left"
}

Expand Down

0 comments on commit 896cf69

Please sign in to comment.