cleaning up

mine
derailed 2020-01-10 13:18:49 -07:00
parent 7949c70929
commit 440aba6400
2 changed files with 4 additions and 3 deletions

View File

@ -216,7 +216,7 @@ func (a *APIClient) RestConfigOrDie() *restclient.Config {
return cfg return cfg
} }
// CachedDiscovery returns a cached discovery client. // CachedDiscoveryOrDie returns a cached discovery client.
func (a *APIClient) CachedDiscoveryOrDie() *disk.CachedDiscoveryClient { func (a *APIClient) CachedDiscoveryOrDie() *disk.CachedDiscoveryClient {
a.mx.Lock() a.mx.Lock()
defer a.mx.Unlock() defer a.mx.Unlock()

View File

@ -103,12 +103,12 @@ func (l *Log) LogCleared() {
}) })
} }
// LogErrored notifies an error occurred. // LogFailed notifies an error occurred.
func (l *Log) LogFailed(err error) { func (l *Log) LogFailed(err error) {
l.app.Flash().Err(err) l.app.Flash().Err(err)
} }
// LogsChanged updates the logs. // LogChanged updates the logs.
func (l *Log) LogChanged(lines []string) { func (l *Log) LogChanged(lines []string) {
log.Debug().Msgf("LOG-CHANGED %d", len(lines)) log.Debug().Msgf("LOG-CHANGED %d", len(lines))
l.app.QueueUpdateDraw(func() { l.app.QueueUpdateDraw(func() {
@ -351,6 +351,7 @@ func (l *Log) textWrapCmd(*tcell.EventKey) *tcell.EventKey {
return nil return nil
} }
// ToggleAutoScrollCmd toggles autoscroll status.
func (l *Log) ToggleAutoScrollCmd(evt *tcell.EventKey) *tcell.EventKey { func (l *Log) ToggleAutoScrollCmd(evt *tcell.EventKey) *tcell.EventKey {
l.indicator.ToggleAutoScroll() l.indicator.ToggleAutoScroll()
return nil return nil