Skip to content

Commit

Permalink
minor rename
Browse files Browse the repository at this point in the history
  • Loading branch information
jub0bs committed Feb 29, 2024
1 parent 1272c0f commit f0a9b6a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion internal/middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ func (cfg *Config) validate() error {
errorMsg.WriteString(patterns[len(patterns)-1])
errorMsg.WriteString(`" require `)
}
errorMsg.WriteString("option risky." + optSIOC + " when ")
errorMsg.WriteString("option risky." + optTIO + " when ")
if cfg.AllowCredentials {
errorMsg.WriteString("credentialed access is enabled")
}
Expand Down
4 changes: 2 additions & 2 deletions internal/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const (
optFO = "FromOrigins"
optPNA = "PrivateNetworkAccess"
optPNANC = "PrivateNetworkAccessInNoCorsModeOnly"
optSIOC = "TolerateInsecureOrigins"
optTIO = "TolerateInsecureOrigins"
optSPSC = "SkipPublicSuffixCheck"
optWAM = "WithAnyMethod"
optWARH = "WithAnyRequestHeaders"
Expand Down Expand Up @@ -435,7 +435,7 @@ func PrivateNetworkAccessInNoCorsModeOnly() Option {
func TolerateInsecureOrigins() Option {
f := func(cfg *Config) error {
if cfg.tmp.TolerateInsecureOrigins {
return util.NewErrorRisky("option " + optSIOC + " used multiple times")
return util.NewErrorRisky("option " + optTIO + " used multiple times")
}
cfg.tmp.TolerateInsecureOrigins = true
return nil
Expand Down

0 comments on commit f0a9b6a

Please sign in to comment.