+ Fix credit rounding
This commit is contained in:
parent
1ae8d041f1
commit
6b6299ac06
@ -441,7 +441,7 @@ class CM_BOT:
|
||||
)
|
||||
soup = BeautifulSoup(response.content, 'html.parser')
|
||||
try:
|
||||
return float(soup.find('table', {'class': 'generalContent'}).find(text=re.compile('Credit Available')).parent.parent.find_all('td')[2].text.replace(",",""))
|
||||
return round(float(soup.find('table', {'class': 'generalContent'}).find(text=re.compile('Credit Available')).parent.parent.find_all('td')[2].text.replace(",","")), 2)
|
||||
except:
|
||||
print(f"Error getting credit.")
|
||||
now = datetime.datetime.now().strftime('%Y%m%d_%H%M')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user