MCPcopy Create free account
hub / github.com/vale-cli/vale / QueryComments

Method QueryComments

internal/core/file.go:385–398  ·  view source on GitHub ↗

QueryComments checks if there has been an in-text comment for this check.

(check string)

Source from the content-addressed store, hash-verified

383
384// QueryComments checks if there has been an in-text comment for this check.
385func (f *File) QueryComments(check string) bool {
386 if f.Comments["off"] {
387 return true
388 }
389 if style, _, ok := strings.Cut(check, "."); ok {
390 if status := f.Comments[style]; status {
391 return true
392 }
393 }
394 if status := f.Comments[check]; status {
395 return true
396 }
397 return false
398}
399
400// ResetComments resets the state of all checks back to active.
401func (f *File) ResetComments() {

Callers 2

lintBlockMethod · 0.80
shouldRunMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected