Redundant godotenv/autoload import in server.go #11

Closed
opened 2026-03-01 19:08:01 +01:00 by clawbot · 0 comments
Collaborator

The blank import _ "github.com/joho/godotenv/autoload" appears in both internal/server/server.go and internal/config/config.go. Per GO_HTTP_SERVER_CONVENTIONS §8 (Environment Loading), this import should appear in only one place.

Since config loading logically precedes server startup, it should remain in internal/config/config.go and be removed from internal/server/server.go.

The blank import `_ "github.com/joho/godotenv/autoload"` appears in both `internal/server/server.go` and `internal/config/config.go`. Per GO_HTTP_SERVER_CONVENTIONS §8 (Environment Loading), this import should appear in only one place. Since config loading logically precedes server startup, it should remain in `internal/config/config.go` and be removed from `internal/server/server.go`.
sneak closed this issue 2026-03-04 01:19:43 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/webhooker#11