diff --git a/output.go b/output.go index da0fc5f..5477892 100644 --- a/output.go +++ b/output.go @@ -87,9 +87,9 @@ func WithProfile(profile Profile) func(*Output) { } } -// WithCache returns a new Output with fore- and background color values +// WithColorCache returns a new Output with fore- and background color values // pre-fetched and cached. -func WithCache(v bool) func(*Output) { +func WithColorCache(v bool) func(*Output) { return func(o *Output) { o.cache = v diff --git a/termenv_test.go b/termenv_test.go index f578d60..8b59d98 100644 --- a/termenv_test.go +++ b/termenv_test.go @@ -386,7 +386,7 @@ func TestPseudoTerm(t *testing.T) { } func TestCache(t *testing.T) { - o := NewOutput(os.Stdout, WithCache(true), WithProfile(TrueColor)) + o := NewOutput(os.Stdout, WithColorCache(true), WithProfile(TrueColor)) if o.cache != true { t.Errorf("Expected cache to be active, got %t", o.cache)