更新
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
package mailx
|
||||
|
||||
import "errors"
|
||||
|
||||
// 包级哨兵错误,供调用方使用 errors.Is / errors.As 精确判断失败原因。
|
||||
var (
|
||||
// ErrSenderNotFound 通道未注册时返回
|
||||
ErrSenderNotFound = errors.New("mailx: sender not found")
|
||||
// ErrInvalidConfig 通道配置缺失/非法时返回
|
||||
ErrInvalidConfig = errors.New("mailx: invalid configuration")
|
||||
// ErrInvalidMessage 消息校验未通过时返回
|
||||
ErrInvalidMessage = errors.New("mailx: invalid message")
|
||||
// ErrSendFailed 发送过程中通道返回错误时返回(可继续用 %w 链式展开底层原因)
|
||||
ErrSendFailed = errors.New("mailx: send failed")
|
||||
)
|
||||
Reference in New Issue
Block a user