[feat] 新增 mqttt OnPublish hook

This commit is contained in:
what 2024-04-25 21:51:08 +08:00
parent fa8fb0753c
commit a4f032b496

View File

@ -75,6 +75,10 @@ func (this MqttHandle) OnMessageDropped(g GlobalParams, topic string, retain boo
return ErrFuncNotImplemented return ErrFuncNotImplemented
} }
func (this MqttHandle) OnPublish(g GlobalParams, topic string, retain bool, qos byte, raw []byte) ([]byte, error) {
return nil, ErrFuncNotImplemented
}
func NewMqttController(container *do.Injector) Mqtt { func NewMqttController(container *do.Injector) Mqtt {
return &MqttHandle{ return &MqttHandle{
Controller: &BaseController{container}, Controller: &BaseController{container},