Add info about cleanwash-moneyback requests
parent
ffc91a26ce
commit
9520adc3d0
|
@ -61,7 +61,7 @@ def cleanwash_return_before(msg):
|
||||||
balance = Decimal(subprocess.check_output(['/home/jmjl/bin/coin','Ju','internal_balance',nick],universal_newlines=True))
|
balance = Decimal(subprocess.check_output(['/home/jmjl/bin/coin','Ju','internal_balance',nick],universal_newlines=True))
|
||||||
if not amount_to_return: amount_to_return = balance
|
if not amount_to_return: amount_to_return = balance
|
||||||
if amount_to_return > balance: return pinhook.plugin.message(f"{msg.nick}: Error, {amount_to_return} is more than what you have with us. (You have {balance}TCN returnable with us)")
|
if amount_to_return > balance: return pinhook.plugin.message(f"{msg.nick}: Error, {amount_to_return} is more than what you have with us. (You have {balance}TCN returnable with us)")
|
||||||
sentproc = subprocess.run(['/home/jmjl/bin/coin','Ju','send',nick,str(amount_to_return.quantize(Decimal('.00'),rounding=ROUND_DOWN))],capture_output=True,text=True)
|
sentproc = subprocess.run(['/home/jmjl/bin/coin','Ju','send',nick,str(amount_to_return.quantize(Decimal('.00'),rounding=ROUND_DOWN)),f"Requested by {msg.nick} at {__import__('time').time()}"],capture_output=True,text=True)
|
||||||
if sentproc.returncode == 0: return pinhook.plugin.message(f"{msg.nick}: Succesfully sent {amount_to_return}TCN back")
|
if sentproc.returncode == 0: return pinhook.plugin.message(f"{msg.nick}: Succesfully sent {amount_to_return}TCN back")
|
||||||
else:
|
else:
|
||||||
err_id = str(uuid.uuid4())
|
err_id = str(uuid.uuid4())
|
||||||
|
|
Loading…
Reference in New Issue