Skip to content

Commit

Permalink
feat: 🔊 add debug logging for MeiliSearch configuration in backend
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan6erbond committed May 10, 2023
1 parent 06c4647 commit b12933a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions server/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ func main() {
})

if os.Getenv("MEILISEARCH_HOST") != "" && os.Getenv("MEILISEARCH_ADMIN_API_KEY") != "" {
app.Settings()
if app.IsDebug() {
log.Println("Configuring MeiliSearch")
}
client := meilisearch.NewClient(os.Getenv("MEILISEARCH_HOST"), os.Getenv("MEILISEARCH_ADMIN_API_KEY"))
meilisearch.RegisterCommands(app, client)
meilisearch.RegisterHooks(app, client)
Expand Down

0 comments on commit b12933a

Please sign in to comment.