fix: user wechat auth
This commit is contained in:
31
backend/app/events/subscribers/provider.gen.go
Executable file
31
backend/app/events/subscribers/provider.gen.go
Executable file
@@ -0,0 +1,31 @@
|
||||
package subscribers
|
||||
|
||||
import (
|
||||
"backend/app/http/users"
|
||||
"backend/providers/event"
|
||||
|
||||
"git.ipao.vip/rogeecn/atom"
|
||||
"git.ipao.vip/rogeecn/atom/container"
|
||||
"git.ipao.vip/rogeecn/atom/contracts"
|
||||
"git.ipao.vip/rogeecn/atom/utils/opt"
|
||||
)
|
||||
|
||||
func Provide(opts ...opt.Option) error {
|
||||
if err := container.Container.Provide(func(
|
||||
__event *event.PubSub,
|
||||
userSvc *users.Service,
|
||||
) (contracts.Initial, error) {
|
||||
obj := &UserRegister{
|
||||
userSvc: userSvc,
|
||||
}
|
||||
if err := obj.Prepare(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
__event.Handle("handler:UserRegister", obj.Topic(), obj.PublishToTopic(), obj.Handler)
|
||||
|
||||
return obj, nil
|
||||
}, atom.GroupInitial); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user