package server import ( "forge.cadoles.com/Cadoles/emissary/internal/config" ) type Option struct { Config config.ServerConfig } type OptionFunc func(*Option) func defaultOption() *Option { return &Option{ Config: config.NewDefaultServerConfig(), } } func WithConfig(conf config.ServerConfig) OptionFunc { return func(opt *Option) { opt.Config = conf } }