Skip to content

Commit

Permalink
further docstring cleanup in results.py
Browse files Browse the repository at this point in the history
  • Loading branch information
danielfromearth committed Feb 7, 2024
1 parent f35c4ea commit 2e57d2f
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions earthaccess/results.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,7 @@ def _filter_fields_(self, fields: List[str]) -> Dict[str, Any]:
return basic_dict

def _filter_related_links(self, filter: str) -> List[str]:
"""
Filter RelatedUrls from the UMM fields on CMR
"""
"""Filter RelatedUrls from the UMM fields on CMR."""
matched_links: List = []
if "RelatedUrls" in self["umm"]:
for link in self["umm"]["RelatedUrls"]:
Expand Down Expand Up @@ -101,7 +99,7 @@ def get_umm(self, umm_field: str) -> Union[str, Dict[str, Any]]:
umm_field: Valid UMM item, i.e. `TemporalExtent`
Returns:
Returns the value of a given field inside the UMM (Unified Metadata Model)
The value of a given field inside the UMM (Unified Metadata Model).
"""
if umm_field in self["umm"]:
return self["umm"][umm_field]
Expand Down Expand Up @@ -290,12 +288,12 @@ def data_links(
Parameters:
access: direct or external.
direct means in-region access for cloud-hosted collections.
direct means in-region access for cloud-hosted collections.
in_region: True if we are running in us-west-2.
It is meant for the store class.
It is meant for the store class.
Returns:
The data link for the requested access type.
The data links for the requested access type.
"""
https_links = self._filter_related_links("GET DATA")
s3_links = self._filter_related_links("GET DATA VIA DIRECT ACCESS")
Expand Down

0 comments on commit 2e57d2f

Please sign in to comment.