Skip to content

Commit

Permalink
Fix Images Gravater
Browse files Browse the repository at this point in the history
  • Loading branch information
BasselArt committed Dec 29, 2024
1 parent 33508d4 commit 42c33e2
Show file tree
Hide file tree
Showing 4 changed files with 1,939 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/handlers/images.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ import (
"github.com/getfider/fider/app/pkg/bus"
"github.com/getfider/fider/app/pkg/crypto"
"github.com/getfider/fider/app/pkg/env"
"github.com/getfider/fider/app/pkg/letteravatar"
"github.com/getfider/fider/app/pkg/log"
"github.com/getfider/fider/app/pkg/web"
"github.com/goenning/imagic"
"github.com/goenning/letteravatar"
)

// LetterAvatar returns a letter gravatar picture based on given name
Expand All @@ -38,7 +38,7 @@ func LetterAvatar() web.HandlerFunc {
}
size = between(size, 50, 200)

img, err := letteravatar.Draw(size, strings.ToUpper(letteravatar.Extract(name)), &letteravatar.Options{
img, err := letteravatar.Draw(size, letteravatar.Extract(name), &letteravatar.Options{
PaletteKey: fmt.Sprintf("%s:%s", id, name),
})
if err != nil {
Expand Down
Loading

0 comments on commit 42c33e2

Please sign in to comment.