Files
onix/pkg/plugin/implementation/requestPreProcessor/cmd/plugin.go
MohitKatare-protean 9bfb65079e Update on review comments
1. changed implementations from camelcase to lowercase
2. added removed initSteps.
3. updated rout struct for model.go
2025-03-29 16:08:28 +05:30

22 lines
499 B
Go

package main
import (
"context"
"net/http"
"strings"
"github.com/beckn/beckn-onix/pkg/plugin/implementation/requestpreprocessor"
)
type provider struct{}
func (p provider) New(ctx context.Context, c map[string]string) (func(http.Handler) http.Handler, error) {
config := &requestpreprocessor.Config{}
if contextKeysStr, ok := c["ContextKeys"]; ok {
config.ContextKeys = strings.Split(contextKeysStr, ",")
}
return requestpreprocessor.NewUUIDSetter(config)
}
var Provider = provider{}