@@ -18,7 +18,7 @@ type Config struct {
1818 QueryParam bool `json:"queryParam,omitempty"`
1919 QueryParamName string `json:"queryParamName,omitempty"`
2020 PathSegment bool `json:"pathSegment,omitempty"`
21- removeQueryParamsOnSuccess bool `json:"removeQueryParamsOnSuccess,omitempty"`
21+ RemoveQueryParamsOnSuccess bool `json:"removeQueryParamsOnSuccess,omitempty"`
2222 Keys []string `json:"keys,omitempty"`
2323 RemoveHeadersOnSuccess bool `json:"removeHeadersOnSuccess,omitempty"`
2424 InternalForwardHeaderName string `json:"internalForwardHeaderName,omitempty"`
@@ -39,7 +39,7 @@ func CreateConfig() *Config {
3939 QueryParam : true ,
4040 QueryParamName : "token" ,
4141 PathSegment : true ,
42- removeQueryParamsOnSuccess :true ,
42+ RemoveQueryParamsOnSuccess :true ,
4343 Keys : make ([]string , 0 ),
4444 RemoveHeadersOnSuccess : true ,
4545 InternalForwardHeaderName : "" ,
@@ -85,7 +85,7 @@ func New(ctx context.Context, next http.Handler, config *Config, name string) (h
8585 queryParam : config .QueryParam ,
8686 queryParamName : config .QueryParamName ,
8787 pathSegment : config .PathSegment ,
88- removeQueryParamsOnSuccess : config .removeQueryParamsOnSuccess ,
88+ removeQueryParamsOnSuccess : config .RemoveQueryParamsOnSuccess ,
8989 keys : config .Keys ,
9090 removeHeadersOnSuccess : config .RemoveHeadersOnSuccess ,
9191 internalForwardHeaderName : config .InternalForwardHeaderName ,
@@ -171,7 +171,7 @@ func (ka *KeyAuth) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
171171 var matchedKey = contains (qs .Get (ka .queryParamName ), ka .keys , true )
172172 if matchedKey != "" {
173173 if ka .removeQueryParamsOnSuccess {
174- qs .Del (ka .queryParamName )
174+ qs .Del (ka .queryParamName )
175175 }
176176 req .URL .RawQuery = qs .Encode ()
177177 ka .ok (rw , req , matchedKey )
0 commit comments