diff --git a/bc.py b/bc.py index e3b1310..0c7b2b9 100644 --- a/bc.py +++ b/bc.py @@ -70,7 +70,11 @@ async def coin(context: Message) -> None: return else: prices = binanceclient.get_all_tickers() - number = float(action[0]) + try: + number = float(action[0]) + except ValueError: + await context.edit('输入错误.\n-bc 数量 币种1 币种2') + return _from = action[1].upper().strip() _to = action[2].upper().strip() front_text = '' diff --git a/list.json b/list.json index 8f1144d..9a9eff3 100644 --- a/list.json +++ b/list.json @@ -442,7 +442,7 @@ }, { "name": "bc", - "version": "1.21", + "version": "1.22", "section": "chat", "maintainer": "Pentacene", "size": "8.0 kb",