Skip to content

Commit

Permalink
lint: suppress on query templ
Browse files Browse the repository at this point in the history
  • Loading branch information
umputun committed Jun 24, 2022
1 parent 78c6f29 commit 8b91a0e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions provider/dev_provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ type DevAuthServer struct {
}

// Run oauth2 dev server on port devAuthPort
func (d *DevAuthServer) Run(ctx context.Context) { //nolint (gocyclo)
func (d *DevAuthServer) Run(ctx context.Context) { // nolint (gocyclo)
if d.Provider.Port == 0 {
d.Provider.Port = defDevAuthPort
}
Expand All @@ -60,9 +60,7 @@ func (d *DevAuthServer) Run(ctx context.Context) { //nolint (gocyclo)

// first time it will be called without username and will ask for one
if !d.Automatic && (r.ParseForm() != nil || r.Form.Get("username") == "") {

formData := struct{ Query template.URL }{Query: template.URL(r.URL.RawQuery)} //nolint:gosec // query is safe

formData := struct{ Query template.URL }{Query: template.URL(r.URL.RawQuery)} //nolint:gosec // query is safes
if err = userFormTmpl.Execute(w, formData); err != nil {
d.Logf("[WARN] can't write, %s", err)
}
Expand Down

0 comments on commit 8b91a0e

Please sign in to comment.