File tree Expand file tree Collapse file tree 3 files changed +1
-15
lines changed Expand file tree Collapse file tree 3 files changed +1
-15
lines changed Original file line number Diff line number Diff line change @@ -847,8 +847,7 @@ func (c *EngineConfig) Validate() error {
847847 }
848848 // Check if the pullPolicy from containers.conf is valid
849849 // if it is invalid returns the error
850- pullPolicy := strings .ToLower (c .PullPolicy )
851- if _ , err := ValidatePullPolicy (pullPolicy ); err != nil {
850+ if _ , err := ParsePullPolicy (c .PullPolicy ); err != nil {
852851 return fmt .Errorf ("invalid pull type from containers.conf %q: %w" , c .PullPolicy , err )
853852 }
854853
Original file line number Diff line number Diff line change @@ -87,8 +87,3 @@ func ParsePullPolicy(s string) (PullPolicy, error) {
8787 return PullPolicyUnsupported , fmt .Errorf ("unsupported pull policy %q" , s )
8888 }
8989}
90-
91- // Deprecated: please use `ParsePullPolicy` instead.
92- func ValidatePullPolicy (s string ) (PullPolicy , error ) {
93- return ParsePullPolicy (s )
94- }
Original file line number Diff line number Diff line change @@ -5,21 +5,13 @@ import (
55 "os"
66 "path/filepath"
77 "regexp"
8- "slices"
98 "time"
109
1110 "github.com/containers/storage/pkg/fileutils"
1211 "github.com/fsnotify/fsnotify"
1312 "github.com/sirupsen/logrus"
1413)
1514
16- // StringInSlice determines if a string is in a string slice, returns bool.
17- //
18- // Deprecated: Use [slices.Contains] instead.
19- func StringInSlice (s string , sl []string ) bool {
20- return slices .Contains (sl , s )
21- }
22-
2315// StringMatchRegexSlice determines if a given string matches one of the given regexes, returns bool
2416func StringMatchRegexSlice (s string , re []string ) bool {
2517 for _ , r := range re {
You can’t perform that action at this time.
0 commit comments