mirror of
https://github.com/zhigang1992/liquid-stacking.git
synced 2026-01-12 17:23:23 +08:00
update print event on token-lqstx::transfer
This commit is contained in:
@@ -109,10 +109,11 @@
|
||||
;; public calls
|
||||
|
||||
(define-public (transfer (amount uint) (sender principal) (recipient principal) (memo (optional (buff 2048))))
|
||||
(begin
|
||||
(let (
|
||||
(shares (get-tokens-to-shares amount)))
|
||||
(asserts! (or (is-eq tx-sender sender) (is-eq contract-caller sender)) err-unauthorised)
|
||||
(try! (ft-transfer? lqstx (get-tokens-to-shares amount) sender recipient))
|
||||
(print { type: "transfer", amount: amount, sender: sender, recipient: recipient, memo: memo })
|
||||
(try! (ft-transfer? lqstx shares sender recipient))
|
||||
(print { notification: "transfer", payload: { amount: amount, shares: shares, sender: sender, recipient: recipient, memo: memo } })
|
||||
(ok true)))
|
||||
|
||||
;; private functions
|
||||
|
||||
@@ -39,7 +39,6 @@ genesis:
|
||||
- pox
|
||||
- pox-2
|
||||
- pox-3
|
||||
- pox-4
|
||||
- lockup
|
||||
- costs-2
|
||||
- costs-3
|
||||
|
||||
Reference in New Issue
Block a user