Skip to content

Commit

Permalink
typo-again
Browse files Browse the repository at this point in the history
  • Loading branch information
dmichaels-harvard committed May 27, 2024
1 parent fcd4b48 commit a551494
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions dcicutils/portal_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ def is_lookup_subtypes(lookup_options: int) -> bool: # noqa
lookup_options = Portal.LOOKUP_UNDEFINED
if schema := self.get_schema(portal_type):
if callable(lookup_strategy):
lookup_options, validator = lookup_strategy(self, self.type, schema, identifying_value)
lookup_options, validator = lookup_strategy(self, portal_type, schema, identifying_value)
if callable(validator):
if validator(schema, identifying_property, identifying_value) is False:
continue
Expand All @@ -494,12 +494,12 @@ def is_lookup_subtypes(lookup_options: int) -> bool: # noqa
lookup_options = Portal.LOOKUP_DEFAULT
if is_lookup_root_first(lookup_options):
results.append(f"/{identifying_value}")
if is_lookup_specified_type(lookup_options) and self.type:
results.append(f"/{self.type}/{identifying_value}")
if is_lookup_specified_type(lookup_options) and portal_type:
results.append(f"/{portal_type}/{identifying_value}")
if is_lookup_root(lookup_options) and not is_lookup_root_first(lookup_options):
results.append(f"/{identifying_value}")
if is_lookup_subtypes(lookup_options):
for subtype_name in self.get_schema_subtype_names(self.type):
for subtype_name in self.get_schema_subtype_names(portal_type):
results.append(f"/{subtype_name}/{identifying_value}")
return results

Expand Down

0 comments on commit a551494

Please sign in to comment.