Notify on unsuccessful release

This commit is contained in:
Mark Veidemanis 2022-04-06 12:21:28 +01:00
parent 37820306e8
commit 74bcf4a5ab
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
2 changed files with 4 additions and 0 deletions

View File

@ -204,6 +204,7 @@ class Transactions(util.Base):
logmessage = f"Release funds unsuccessful: {rtrn['message']}" logmessage = f"Release funds unsuccessful: {rtrn['message']}"
self.log.error(logmessage) self.log.error(logmessage)
self.irc.sendmsg(logmessage) self.irc.sendmsg(logmessage)
self.ux.notify.notify_release_unsuccessful(trade_id)
return return
# Parse the escrow release response # Parse the escrow release response

View File

@ -41,3 +41,6 @@ class Notify(util.Base):
def notify_tx_lookup_failed(self, currency, amount, reference, code, trade_id=None): def notify_tx_lookup_failed(self, currency, amount, reference, code, trade_id=None):
self.sendmsg(f"Unknown TX [{code}]: {amount}{currency} ({reference}) for {trade_id}", title=code, tags="tx", priority="5") self.sendmsg(f"Unknown TX [{code}]: {amount}{currency} ({reference}) for {trade_id}", title=code, tags="tx", priority="5")
def notify_release_unsuccessful(self, trade_id):
self.sendmsg(f"Release unsuccessful for {trade_id}", title="Unsuccessful release", tags="tx", priority="5")