Skip to content

Commit

Permalink
fix type checking
Browse files Browse the repository at this point in the history
  • Loading branch information
DenizYil committed Aug 10, 2023
1 parent 286bf2d commit 75435db
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions terracotta/server/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class MetadataColumnsSchema(Schema):
@pre_load
def validate_columns(
self, data: Mapping[str, Any], **kwargs: Any
) -> Dict[str, Any]:
) -> Dict[str, Any] | Mapping[str, Any]:
columns = data.get("columns")

if columns:
Expand Down Expand Up @@ -148,7 +148,7 @@ def get_multiple_metadata() -> Response:
from terracotta.handlers.metadata import multiple_metadata

datasets_schema = MultipleMetadataDatasetsSchema()
datasets = datasets_schema.load(request.json).get("keys")
datasets = datasets_schema.load(request.json or {}).get("keys")

columns_schema = MetadataColumnsSchema()
columns = columns_schema.load(request.args).get("columns")
Expand Down

0 comments on commit 75435db

Please sign in to comment.