mirror of
https://github.com/tw93/Mole.git
synced 2026-02-07 16:49:16 +00:00
Go code formatting optimization
This commit is contained in:
@@ -308,9 +308,10 @@ func renderMemoryCard(mem MemoryStatus) cardData {
|
||||
if mem.Pressure != "" {
|
||||
pressureStyle := okStyle
|
||||
pressureText := "Status " + mem.Pressure
|
||||
if mem.Pressure == "warn" {
|
||||
switch mem.Pressure {
|
||||
case "warn":
|
||||
pressureStyle = warnStyle
|
||||
} else if mem.Pressure == "critical" {
|
||||
case "critical":
|
||||
pressureStyle = dangerStyle
|
||||
}
|
||||
lines = append(lines, pressureStyle.Render(pressureText))
|
||||
|
||||
Reference in New Issue
Block a user