MCPcopy Create free account
hub / github.com/aiprodcoder/MIXAPI / NotifyRootUser

Function NotifyRootUser

service/user_notify.go:11–17  ·  view source on GitHub ↗
(t string, subject string, content string)

Source from the content-addressed store, hash-verified

9)
10
11func NotifyRootUser(t string, subject string, content string) {
12 user := model.GetRootUser().ToBaseUser()
13 err := NotifyUser(user.Id, user.Email, user.GetSetting(), dto.NewNotify(t, subject, content, nil))
14 if err != nil {
15 common.SysError(fmt.Sprintf("failed to notify root user: %s", err.Error()))
16 }
17}
18
19func NotifyUser(userId int, userEmail string, userSetting dto.UserSetting, data dto.Notify) error {
20 notifyType := userSetting.NotifyType

Callers 3

testAllChannelsFunction · 0.92
DisableChannelFunction · 0.85
EnableChannelFunction · 0.85

Calls 7

GetRootUserFunction · 0.92
NewNotifyFunction · 0.92
SysErrorFunction · 0.92
NotifyUserFunction · 0.85
ToBaseUserMethod · 0.80
ErrorMethod · 0.80
GetSettingMethod · 0.45

Tested by

no test coverage detected