fix(notif): use markdown format if invalid

This commit is contained in:
yusing
2025-09-10 22:57:54 +08:00
parent 226ee2e5e5
commit c9c5677b35
2 changed files with 2 additions and 3 deletions

View File

@@ -30,7 +30,7 @@ var (
// Validate implements the utils.CustomValidator interface.
func (base *ProviderBase) Validate() gperr.Error {
if base.Format == nil {
if base.Format == nil || base.Format.string == "" {
base.Format = LogFormatMarkdown
}
if !strings.HasPrefix(base.URL, "http://") && !strings.HasPrefix(base.URL, "https://") {