Bug fix: jeb_utils.utils.is_number could return True even if the base is 0 which is mathematically incorrect.
This commit is contained in:
@@ -38,6 +38,8 @@ def is_number(string: str, base: int = 10) -> bool:
|
||||
:return: ``True`` if the string is a number, otherwise ``False``
|
||||
:rtype: bool
|
||||
'''
|
||||
if base == 0:
|
||||
return False
|
||||
if not string:
|
||||
return False
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user