mirror of
https://github.com/mikefarah/yq.git
synced 2026-07-05 20:15:36 +00:00
Compare commits
2 Commits
a48a63e2c1
...
a70cda7fd5
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a70cda7fd5 | ||
|
|
b04cdeea7d |
@ -3,6 +3,7 @@ package yqlib
|
||||
import (
|
||||
"fmt"
|
||||
"path/filepath"
|
||||
"slices"
|
||||
"strings"
|
||||
)
|
||||
|
||||
@ -95,12 +96,7 @@ func (f *Format) MatchesName(name string) bool {
|
||||
if f.FormalName == name {
|
||||
return true
|
||||
}
|
||||
for _, n := range f.Names {
|
||||
if n == name {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
return slices.Contains(f.Names, name)
|
||||
}
|
||||
|
||||
func (f *Format) GetConfiguredEncoder() Encoder {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user