Skip to content

Commit

Permalink
Merge pull request #108 from TripalCultivate/g4.90-updateImporterWith…
Browse files Browse the repository at this point in the history
…NewValidators

G4.90 Utilize all remaining new validators
  • Loading branch information
laceysanderson authored Oct 24, 2024
2 parents 7a4da98 + 56cae6a commit 79bb75f
Show file tree
Hide file tree
Showing 15 changed files with 510 additions and 1,204 deletions.

Large diffs are not rendered by default.

114 changes: 0 additions & 114 deletions trpcultivate_phenotypes/src/Plugin/Validators/DataFile.php

This file was deleted.

135 changes: 0 additions & 135 deletions trpcultivate_phenotypes/src/Plugin/Validators/Genus.php

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@
* Validate that genus exists and is configured.
*
* @TripalCultivatePhenotypesValidator(
* id = "trpcultivate_phenotypes_validator_genus_exists",
* id = "genus_exists",
* validator_name = @Translation("Genus Exists and Configured Validator"),
* input_types = {"metadata"}
* )
*/
class genusExists extends TripalCultivatePhenotypesValidatorBase implements ContainerFactoryPluginInterface {
class GenusExists extends TripalCultivatePhenotypesValidatorBase implements ContainerFactoryPluginInterface {

/**
* Genus Ontology Service;
Expand Down Expand Up @@ -66,7 +66,7 @@ public static function create(ContainerInterface $container, array $configuratio
}

/**
* Validate that genus provided exists and configured.
* Validate that genus provided exists and is configured.
*
* @param array $form_values
* The values entered to any form field elements implemented by the importer.
Expand All @@ -88,7 +88,7 @@ public function validateMetadata(array $form_values) {

// Failed to locate the genus field element.
if (!array_key_exists($expected_field_key, $form_values)) {
throw new \Exception('Failed to locate genus field element. genusExists validator expects a form field element name genus.');
throw new \Exception('Failed to locate genus field element. GenusExists validator expects a form field element name genus.');
}

// Validator response values for a valid genus value.
Expand Down
Loading

0 comments on commit 79bb75f

Please sign in to comment.