Skip to content

Commit c258d11

Browse files
committed
chore: lint the code
1 parent 2e0ef39 commit c258d11

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

internal/server/service.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,6 @@ func (s *Service) createCertManager(hosts []string, options ServiceOptions) (Cer
323323
}
324324

325325
hostPolicy, err := s.createAutoCertHostPolicy(hosts, options)
326-
327326
if err != nil {
328327
return nil, err
329328
}
@@ -337,14 +336,13 @@ func (s *Service) createCertManager(hosts []string, options ServiceOptions) (Cer
337336
}
338337

339338
func (s *Service) createAutoCertHostPolicy(hosts []string, options ServiceOptions) (autocert.HostPolicy, error) {
340-
slog.Info("createAutoCertHostPolicy called", options.TLSOnDemandUrl, len(hosts), "🚨", "ok")
339+
slog.Info("createAutoCertHostPolicy called", "url", options.TLSOnDemandUrl)
341340

342341
if options.TLSOnDemandUrl == "" {
343342
return autocert.HostWhitelist(hosts...), nil
344343
}
345344

346345
_, err := url.ParseRequestURI(options.TLSOnDemandUrl)
347-
348346
if err != nil {
349347
slog.Error("Unable to parse the tls_on_demand_url URL")
350348
return nil, err
@@ -353,10 +351,9 @@ func (s *Service) createAutoCertHostPolicy(hosts []string, options ServiceOption
353351
slog.Info("Will use the tls_on_demand_url URL")
354352

355353
return func(ctx context.Context, host string) error {
356-
slog.Info("Get a certificate for", host, "🤞")
354+
slog.Info("Get a certificate", "host", host)
357355

358356
resp, err := http.Get(fmt.Sprintf("%s?host=%s", options.TLSOnDemandUrl, url.QueryEscape(host)))
359-
360357
if err != nil {
361358
slog.Error("Unable to reach the TLS on demand URL", host, err)
362359
return err

0 commit comments

Comments
 (0)