mirror of
https://github.com/maxlerebourg/crowdsec-bouncer-traefik-plugin.git
synced 2026-07-21 11:38:59 +02:00
fix lint
This commit is contained in:
+2
-1
@@ -144,6 +144,7 @@ func New(ctx context.Context, next http.Handler, config *Config, name string) (h
|
|||||||
}
|
}
|
||||||
|
|
||||||
// TODO the serve HTTP should be split as it's too long.
|
// TODO the serve HTTP should be split as it's too long.
|
||||||
|
// ServeHTTP principal function of plugin
|
||||||
func (a *Bouncer) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
|
func (a *Bouncer) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
|
||||||
if !a.enabled {
|
if !a.enabled {
|
||||||
log.Printf("Crowdsec Bouncer not enabled")
|
log.Printf("Crowdsec Bouncer not enabled")
|
||||||
@@ -244,7 +245,7 @@ func (a *Bouncer) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
|
|||||||
|
|
||||||
// Decision: Body returned from Crowdsec LAPI.
|
// Decision: Body returned from Crowdsec LAPI.
|
||||||
type Decision struct {
|
type Decision struct {
|
||||||
Id int `json:"id"`
|
ID int `json:"id"`
|
||||||
Origin string `json:"origin"`
|
Origin string `json:"origin"`
|
||||||
Type string `json:"type"`
|
Type string `json:"type"`
|
||||||
Scope string `json:"scope"`
|
Scope string `json:"scope"`
|
||||||
|
|||||||
Reference in New Issue
Block a user