Skip to content

Commit

Permalink
Return none like previous optional when no arguments are passed
Browse files Browse the repository at this point in the history
  • Loading branch information
k-fish committed Oct 16, 2023
1 parent a91f25a commit 55dfc2a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/sentry/snuba/metrics/extraction.py
Original file line number Diff line number Diff line change
Expand Up @@ -733,6 +733,9 @@ def _field_for_hash(self) -> Optional[str]:
elif self.op == "on_demand_apdex":
return f"{self.op}:{self._arguments[0]}"

if not self._arguments:
return None

return self._arguments[0]

def _query_for_hash(self):
Expand Down

0 comments on commit 55dfc2a

Please sign in to comment.