Skip to content

Commit

Permalink
testing perf
Browse files Browse the repository at this point in the history
  • Loading branch information
stormofice committed Oct 3, 2023
1 parent 3f0eb4d commit d221e21
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
13 changes: 6 additions & 7 deletions cmd/mensatt/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
"github.com/mensatt/backend/pkg/utils"
"log"
"path/filepath"
"time"
)

func main() {
Expand Down Expand Up @@ -69,12 +68,12 @@ func main() {
sentryOptions.Debug = true
}

err = sentry.Init(sentryOptions)
if err != nil {
log.Fatalln("Sentry initialization failed:", err)
}
// Flush buffered events before the program terminates
defer sentry.Flush(2 * time.Second)
// err = sentry.Init(sentryOptions)
// if err != nil {
// log.Fatalln("Sentry initialization failed:", err)
// }
// // Flush buffered events before the program terminates
// defer sentry.Flush(2 * time.Second)

// Details for database connection
username, err := utils.GetOrFile("DATABASE_USERNAME")
Expand Down
2 changes: 1 addition & 1 deletion internal/images/images.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func imageHandler(ip *imageuploader.ImageUploader) gin.HandlerFunc {
return
}

data, _, err := img.ExportWebp(&vips.WebpExportParams{Quality: quality})
data, _, err := img.ExportWebp(&vips.WebpExportParams{})
if err != nil {
c.JSON(http.StatusInternalServerError, gin.H{"error": "error exporting image"})
return
Expand Down

0 comments on commit d221e21

Please sign in to comment.