From 39f0a17e6220e137387e651d3d8db69b0121f522 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sat, 11 Dec 2021 20:08:03 +0100 Subject: [PATCH] Fix formatting --- freqtrade/rpc/telegram.py | 6 +++--- tests/rpc/test_rpc_apiserver.py | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/freqtrade/rpc/telegram.py b/freqtrade/rpc/telegram.py index 206e2d4f7..f333dc5db 100644 --- a/freqtrade/rpc/telegram.py +++ b/freqtrade/rpc/telegram.py @@ -1184,7 +1184,7 @@ class Telegram(RPCHandler): Handler for /bl_delete Deletes pair(s) from current blacklist """ - self.send_blacklist_msg(self._rpc._rpc_blacklist_delete(context.args)) + self.send_blacklist_msg(self._rpc._rpc_blacklist_delete(context.args or [])) @authorized_only def _logs(self, update: Update, context: CallbackContext) -> None: @@ -1265,8 +1265,8 @@ class Telegram(RPCHandler): "*/whitelist:* `Show current whitelist` \n" "*/blacklist [pair]:* `Show current blacklist, or adds one or more pairs " "to the blacklist.` \n" - "*/blacklist_delete [pairs]| /bl_delete [pairs]:* `Delete pair / pattern from blacklist. " - "Will reset on reload_conf.` \n" + "*/blacklist_delete [pairs]| /bl_delete [pairs]:* " + "`Delete pair / pattern from blacklist. Will reset on reload_conf.` \n" "*/reload_config:* `Reload configuration file` \n" "*/unlock :* `Unlock this Pair (or this lock id if it's numeric)`\n" diff --git a/tests/rpc/test_rpc_apiserver.py b/tests/rpc/test_rpc_apiserver.py index e6d80880b..d6a58322a 100644 --- a/tests/rpc/test_rpc_apiserver.py +++ b/tests/rpc/test_rpc_apiserver.py @@ -987,6 +987,7 @@ def test_api_blacklist(botclient, mocker): "errors": {}, } + def test_api_whitelist(botclient): ftbot, client = botclient