MCPcopy Create free account
hub / github.com/bytebase/bytebase / levelColor

Function levelColor

backend/plugin/webhook/slack/slack.go:84–95  ·  view source on GitHub ↗
(level webhook.Level)

Source from the content-addressed store, hash-verified

82}
83
84func levelColor(level webhook.Level) string {
85 switch level {
86 case webhook.WebhookSuccess:
87 return "#2EB67D"
88 case webhook.WebhookWarn:
89 return "#ECB22E"
90 case webhook.WebhookError:
91 return "#E01E5A"
92 default:
93 return "#1264A3"
94 }
95}
96
97func levelEmoji(level webhook.Level) string {
98 switch level {

Callers 2

TestLevelColorFunction · 0.85
BuildMessageFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestLevelColorFunction · 0.68