internal/utils/utils.go
Function CountFilesRecursive
has 5 return statements (exceeds 4 allowed). Open
Open
func CountFilesRecursive(dir string) (int, error) {
if _, err := os.Stat(dir); os.IsNotExist(err) {
return 0, nil
}
Function ValidatePathSection
has 5 return statements (exceeds 4 allowed). Open
Open
func ValidatePathSection(path string) error {
// throw an error if the path contains illegal characters
if illegalPath.MatchString(path) {
return errors.New("Illegal characters in path: " + path)
}