Class: Ronin::App::Validations::ImportParams
- Inherits:
-
Dry::Validation::Contract
- Object
- Dry::Validation::Contract
- Ronin::App::Validations::ImportParams
- Defined in:
- lib/ronin/app/validations/import_params.rb
Overview
Validations for the form params submitted to POST /import
.
Constant Summary collapse
- VALID_FILE_EXTS =
Mapping of
type
values to their set of valid file extension names. { 'nmap' => Set['.xml'], 'masscan' => Masscan::OutputFile::FILE_FORMATS.keys.to_set }
Class Method Summary collapse
-
.call(params) ⇒ Dry::Validation::Result
Initializes and calls the validation contract.
Class Method Details
.call(params) ⇒ Dry::Validation::Result
Initializes and calls the validation contract.
64 65 66 |
# File 'lib/ronin/app/validations/import_params.rb', line 64 def self.call(params) new.call(params) end |