From 67fa25d8a38ba70516f87b20324b6c7e77201982 Mon Sep 17 00:00:00 2001 From: Cyril David Date: Wed, 27 Jan 2021 23:24:02 -0800 Subject: [PATCH] Cleanup const declarations --- internal/display/logs.go | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/internal/display/logs.go b/internal/display/logs.go index 941007626..1fa18665e 100644 --- a/internal/display/logs.go +++ b/internal/display/logs.go @@ -14,8 +14,15 @@ import ( const ( notApplicable = "N/A" + + logCategorySuccess logCategory = iota + logCategoryWarning + logCategoryFailure + logCategoryUnknown ) +type logCategory int + var _ View = &logView{} type logView struct { @@ -137,15 +144,6 @@ func (v *logView) Extras() []string { return []string{strings.Join(res, "\n")} } -type logCategory int - -const ( - logCategorySuccess logCategory = iota - logCategoryWarning - logCategoryFailure - logCategoryUnknown -) - func (v *logView) category() logCategory { if strings.HasPrefix(v.GetType(), "s") { return logCategorySuccess