Skip to content

Commit 2a05b28

Browse files
refactor is_account_id
1 parent d4d74cb commit 2a05b28

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
@@ -67,12 +67,4 @@ def get_aws_region() -> str:
6767

6868

6969
def is_account_id(input_str: str) -> bool:
70-
if input_str is None:
71-
return False
72-
73-
try:
74-
int(input_str)
75-
except ValueError:
76-
return False
77-
78-
return True
70+
return input_str is not None and input_str.isdigit()

0 commit comments

Comments
 (0)