19 lines
273 B
Go
19 lines
273 B
Go
package web
|
|
|
|
import (
|
|
"github.com/liwei1dao/lego/utils/mapstructure"
|
|
)
|
|
|
|
type (
|
|
Options struct {
|
|
Port int
|
|
}
|
|
)
|
|
|
|
func (this *Options) LoadConfig(settings map[string]interface{}) (err error) {
|
|
if settings != nil {
|
|
err = mapstructure.Decode(settings, this)
|
|
}
|
|
return
|
|
}
|