Skip to content

Commit

Permalink
Merge pull request #7 from prratek/bug/media-insights-metrics
Browse files Browse the repository at this point in the history
convert metrics list to string
  • Loading branch information
prratek authored Mar 16, 2022
2 parents 86f6a0d + a40714f commit dfdd9c6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tap_instagram/streams.py
Original file line number Diff line number Diff line change
Expand Up @@ -501,9 +501,10 @@ def get_url_params(
self, context: Optional[dict], next_page_token: Optional[Any]
) -> Dict[str, Any]:
params = super().get_url_params(context, next_page_token)
params["metric"] = self._metrics_for_media_type(
metrics = self._metrics_for_media_type(
context["media_type"], context["media_product_type"]
)
params["metric"] = ",".join(metrics)
return params

def validate_response(self, response: requests.Response) -> None:
Expand Down Expand Up @@ -664,9 +665,10 @@ def get_url_params(
self, context: Optional[dict], next_page_token: Optional[Any]
) -> Dict[str, Any]:
params = super().get_url_params(context, next_page_token)
params["metric"] = self._metrics_for_media_type(
metrics = self._metrics_for_media_type(
context["media_type"], context["media_product_type"]
)
params["metric"] = ",".join(metrics)
return params

def validate_response(self, response: requests.Response) -> None:
Expand Down

0 comments on commit dfdd9c6

Please sign in to comment.