Merge branch 'main' into improve-wireguard

This commit is contained in:
Myzel394 2025-03-23 17:35:35 +01:00
commit 5de2711b03

View File

@ -47,17 +47,17 @@ func (v PathValue) GetTypeDescription() []string {
} }
func (v PathValue) DeprecatedCheckIsValid(value string) []*InvalidValue { func (v PathValue) DeprecatedCheckIsValid(value string) []*InvalidValue {
if !utils.DoesPathExist(value) {
if v.RequiredType == PathTypeExistenceOptional { if v.RequiredType == PathTypeExistenceOptional {
return nil return nil
} else { }
if !utils.DoesPathExist(value) {
return []*InvalidValue{{ return []*InvalidValue{{
Err: PathDoesNotExistError{}, Err: PathDoesNotExistError{},
Start: 0, Start: 0,
End: uint32(len(value)), End: uint32(len(value)),
}} }}
} }
}
isValid := false isValid := false