We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f3563dd commit 3227de8Copy full SHA for 3227de8
1 file changed
sentry_sdk/integrations/cohere/utils.py
@@ -5,15 +5,13 @@
5
if TYPE_CHECKING:
6
from typing import Any
7
8
-_MISSING = object()
9
-
10
11
def transitive_getattr(obj, *attrs):
12
# type: (Any, str) -> Any
13
current = obj
14
for attr in attrs:
15
- current = getattr(current, attr, _MISSING)
16
- if current is _MISSING:
+ current = getattr(current, attr, None)
+ if not current:
17
return None
18
return current
19
0 commit comments