Skip to content

Commit 89fe10e

Browse files
committed
Add: Notification urgent level and list of AllowedLevels
1 parent a753feb commit 89fe10e

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

pkg/notifications/model.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,16 @@ const (
3939
LevelInfo Level = "info"
4040
LevelWarning Level = "warning"
4141
LevelError Level = "error"
42+
LevelUrgent Level = "urgent"
4243
)
4344

45+
var AllowedLevels = []Level{
46+
LevelInfo,
47+
LevelWarning,
48+
LevelError,
49+
LevelUrgent,
50+
}
51+
4452
// toNotificationModel converts a Notification to the rest model for the notification service.
4553
// It also adds the current time as timestamp if it is not set.
4654
func toNotificationModel(n Notification) notificationModel {

0 commit comments

Comments
 (0)