diff --git a/pkg/service/init.go b/pkg/service/init.go index 22b947b..8908c5a 100644 --- a/pkg/service/init.go +++ b/pkg/service/init.go @@ -29,6 +29,15 @@ type AmfApp struct { var AMF *AmfApp func GetApp() *AmfApp { + if AMF == nil { + amf := &AmfApp{ + // consumer: consumer, + + } + consumer, _ := consumer.NewConsumer(AMF) + amf.consumer = consumer + AMF = amf + } return AMF }