From f981b991c0151fdb5de99e5e271dec313b1308cc Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Fri, 12 Mar 2021 02:07:50 +0100 Subject: [PATCH] Fix ineffectual assignment in spinner example --- examples/spinners/main.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/spinners/main.go b/examples/spinners/main.go index 165b453..a67c547 100644 --- a/examples/spinners/main.go +++ b/examples/spinners/main.go @@ -86,13 +86,14 @@ func (m *model) resetSpinner() { } func (m model) View() (s string) { - gap := " " + var gap string switch m.index { case 1: gap = "" default: gap = " " } + s += fmt.Sprintf("\n %s%s%s\n\n", m.spinner.View(), gap, textStyle("Spinning...")) s += helpStyle("h/l, ←/→: change spinner • q: exit\n") return