mirror of
https://github.com/RoboSats/robosats.git
synced 2025-01-18 20:21:35 +00:00
Fix message your order is public
This commit is contained in:
parent
8001e148d7
commit
408516241d
@ -261,6 +261,7 @@ class Logics:
|
|||||||
order.taker_bond = None
|
order.taker_bond = None
|
||||||
order.trade_escrow = None
|
order.trade_escrow = None
|
||||||
cls.publish_order(order)
|
cls.publish_order(order)
|
||||||
|
send_message.delay(order.id,'order_published')
|
||||||
# Reward maker with part of the taker bond
|
# Reward maker with part of the taker bond
|
||||||
cls.add_slashed_rewards(taker_bond, order.maker.profile)
|
cls.add_slashed_rewards(taker_bond, order.maker.profile)
|
||||||
return True
|
return True
|
||||||
@ -290,6 +291,7 @@ class Logics:
|
|||||||
order.taker_bond = None
|
order.taker_bond = None
|
||||||
order.trade_escrow = None
|
order.trade_escrow = None
|
||||||
cls.publish_order(order)
|
cls.publish_order(order)
|
||||||
|
send_message.delay(order.id,'order_published')
|
||||||
# Reward maker with part of the taker bond
|
# Reward maker with part of the taker bond
|
||||||
cls.add_slashed_rewards(taker_bond, order.maker.profile)
|
cls.add_slashed_rewards(taker_bond, order.maker.profile)
|
||||||
return True
|
return True
|
||||||
@ -608,6 +610,7 @@ class Logics:
|
|||||||
if valid:
|
if valid:
|
||||||
order.taker = None
|
order.taker = None
|
||||||
cls.publish_order(order)
|
cls.publish_order(order)
|
||||||
|
send_message.delay(order.id,'order_published')
|
||||||
# Reward maker with part of the taker bond
|
# Reward maker with part of the taker bond
|
||||||
cls.add_slashed_rewards(order.taker_bond, order.maker.profile)
|
cls.add_slashed_rewards(order.taker_bond, order.maker.profile)
|
||||||
return True, None
|
return True, None
|
||||||
@ -659,7 +662,7 @@ class Logics:
|
|||||||
order.expires_at = order.created_at + timedelta(
|
order.expires_at = order.created_at + timedelta(
|
||||||
seconds=Order.t_to_expire[Order.Status.PUB])
|
seconds=Order.t_to_expire[Order.Status.PUB])
|
||||||
order.save()
|
order.save()
|
||||||
send_message.delay(order.id,'order_published')
|
# send_message.delay(order.id,'order_published') # too spammy
|
||||||
return
|
return
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
@ -668,6 +671,7 @@ class Logics:
|
|||||||
return True
|
return True
|
||||||
elif LNNode.validate_hold_invoice_locked(order.maker_bond):
|
elif LNNode.validate_hold_invoice_locked(order.maker_bond):
|
||||||
cls.publish_order(order)
|
cls.publish_order(order)
|
||||||
|
send_message.delay(order.id,'order_published')
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user