Skip to content

Commit 5bc41ee

Browse files
refactor is_account_id
1 parent 8ac666a commit 5bc41ee

File tree

1 file changed

+1
-9
lines changed
  • aws-opentelemetry-distro/src/amazon/opentelemetry/distro

1 file changed

+1
-9
lines changed

aws-opentelemetry-distro/src/amazon/opentelemetry/distro/_utils.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,4 @@ def get_aws_region() -> Optional[str]:
7878

7979

8080
def is_account_id(input_str: str) -> bool:
81-
if input_str is None:
82-
return False
83-
84-
try:
85-
int(input_str)
86-
except ValueError:
87-
return False
88-
89-
return True
81+
return input_str is not None and input_str.isdigit()

0 commit comments

Comments
 (0)