Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
Signed-off-by: Jirka Kremser <jiri.kremser@gmail.com>
  • Loading branch information
jkremser committed Nov 19, 2024
1 parent b80da17 commit b11d018
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion rest/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ func Init(restApiPort int, info prometheus.Labels, ms types.MemStore, isDebug bo
gin.SetMode(gin.ReleaseMode)
}
router := gin.New()
router.SetTrustedProxies(nil)
if err := router.SetTrustedProxies(nil); err != nil {
a.lggr.Error(err, "Disabling trusted proxies failed")
}
docs.SwaggerInfo.BasePath = "/"
router.GET("/swagger/*any", ginSwagger.WrapHandler(swaggerfiles.Handler))
router.GET("/memstore/names", a.getMetricNames)
Expand Down

0 comments on commit b11d018

Please sign in to comment.