Class: AocCli::Validators::PathValidator
- Inherits:
-
Kangaru::Validator
- Object
- Kangaru::Validator
- AocCli::Validators::PathValidator
- Defined in:
- lib/aoc_cli/validators/path_validator.rb
Instance Method Summary collapse
Instance Method Details
#validate ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'lib/aoc_cli/validators/path_validator.rb', line 4 def validate return add_error!(ERRORS[:blank]) if value.nil? if params[:exists] == false validate_path_does_not_exist! else validate_path_exists! end end |