Move util func to utils
This commit is contained in:
parent
2229437a7f
commit
abd272635e
10
restic.go
10
restic.go
@ -16,16 +16,6 @@ var (
|
||||
ErrRepoNotFound = errors.Join(errors.New("repository not found or uninitialized"), ErrRestic)
|
||||
)
|
||||
|
||||
func lineIn(needle string, haystack []string) bool {
|
||||
for _, line := range haystack {
|
||||
if line == needle {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
func maybeAddArgString(args []string, name, value string) []string {
|
||||
if value != "" {
|
||||
return append(args, name, value)
|
||||
|
Loading…
Reference in New Issue
Block a user