fix: lint for var blocks

This commit is contained in:
Raphael Amorim
2025-07-30 11:28:25 +02:00
parent 760e5c4f12
commit 3839c364d6
2 changed files with 5 additions and 9 deletions

View File

@@ -21,10 +21,8 @@ import (
"github.com/charmbracelet/crush/internal/message"
)
var (
// Pre-compiled regex for parsing context limit errors.
contextLimitRegex = regexp.MustCompile(`input length and ` + "`max_tokens`" + ` exceed context limit: (\d+) \+ (\d+) > (\d+)`)
)
// Pre-compiled regex for parsing context limit errors.
var contextLimitRegex = regexp.MustCompile(`input length and ` + "`max_tokens`" + ` exceed context limit: (\d+) \+ (\d+) > (\d+)`)
type anthropicClient struct {
providerOptions providerClientOptions

View File

@@ -15,11 +15,9 @@ import (
"github.com/sahilm/fuzzy"
)
var (
// Pre-compiled regex for checking if a string is alphanumeric.
// Note: This is duplicated from filterable.go to avoid circular dependencies.
alphanumericRegexGroup = regexp.MustCompile(`^[a-zA-Z0-9]*$`)
)
// Pre-compiled regex for checking if a string is alphanumeric.
// Note: This is duplicated from filterable.go to avoid circular dependencies.
var alphanumericRegexGroup = regexp.MustCompile(`^[a-zA-Z0-9]*$`)
type FilterableGroupList[T FilterableItem] interface {
GroupedList[T]