Flake8 fix
This commit is contained in:
parent
9bdfe6fdfc
commit
f9783b7aae
@ -288,7 +288,8 @@ class Telegram(RPCHandler):
|
|||||||
is_fill = msg['type'] == RPCMessageType.SELL_FILL
|
is_fill = msg['type'] == RPCMessageType.SELL_FILL
|
||||||
is_sub_trade = msg.get('sub_trade')
|
is_sub_trade = msg.get('sub_trade')
|
||||||
is_sub_profit = msg['profit_amount'] != msg.get('cumulative_profit')
|
is_sub_profit = msg['profit_amount'] != msg.get('cumulative_profit')
|
||||||
profit_prefix = ('Sub ' if is_sub_profit else 'Cumulative ') if is_sub_trade else ''
|
profit_prefix = ('Sub ' if is_sub_profit
|
||||||
|
else 'Cumulative ') if is_sub_trade else ''
|
||||||
if is_sub_profit and is_sub_trade:
|
if is_sub_profit and is_sub_trade:
|
||||||
if self._rpc._fiat_converter:
|
if self._rpc._fiat_converter:
|
||||||
cp_fiat = self._rpc._fiat_converter.convert_amount(
|
cp_fiat = self._rpc._fiat_converter.convert_amount(
|
||||||
@ -296,7 +297,8 @@ class Telegram(RPCHandler):
|
|||||||
cp_extra = f" / {cp_fiat:.3f} {msg['fiat_currency']})"
|
cp_extra = f" / {cp_fiat:.3f} {msg['fiat_currency']})"
|
||||||
else:
|
else:
|
||||||
cp_extra = ''
|
cp_extra = ''
|
||||||
cp_extra = f"*Cumulative Profit:* (`{msg['cumulative_profit']:.8f} msg['stake_currency']{cp_extra}`\n"
|
cp_extra = f"*Cumulative Profit:* (`{msg['cumulative_profit']:.8f}\
|
||||||
|
f"{msg['stake_currency']}{cp_extra}`)\n"
|
||||||
else:
|
else:
|
||||||
cp_extra = ''
|
cp_extra = ''
|
||||||
message = (
|
message = (
|
||||||
|
Loading…
Reference in New Issue
Block a user