tx · VnkVVfMnBqMde3mGUxfomWYhju3B5zVP3GJRaKzTNoX

3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac:  -0.03700000 Waves

2023.05.15 13:00 [2578924] smart account 3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac > SELF 0.00000000 Waves

{ "type": 13, "id": "VnkVVfMnBqMde3mGUxfomWYhju3B5zVP3GJRaKzTNoX", "fee": 3700000, "feeAssetId": null, "timestamp": 1684144869969, "version": 2, "chainId": 84, "sender": "3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac", "senderPublicKey": "9yW1Jko9uspFMWxZL7MsaEnTH66KnoCqj69k36PKqZq3", "proofs": [ "8Vxj49rfKAPt1jG2ULHGUruqTfxNjPruztyLWSYiiHd7WT2tMhhvtKBswn4kozEMGUFnmPdNHkyQj71konqgAcT" ], "script": "base64:BgIPCAISAwoBCBIGCgQEBAQIDQANa19pbml0aWFsaXplZAINa19pbml0aWFsaXplZAAUa19jb29yZGluYXRvckFkZHJlc3MCFGtfY29vcmRpbmF0b3JBZGRyZXNzABFrX3N0YWtpbmdfYWRkcmVzcwIRa19zdGFraW5nX2FkZHJlc3MAEWtfZmFybWluZ19hZGRyZXNzAhFrX2Zhcm1pbmdfYWRkcmVzcwAPa192YXVsdF9hZGRyZXNzAg9rX3ZhdWx0X2FkZHJlc3MAD2tfYWRtaW5fYWRkcmVzcwIPa19hZG1pbl9hZGRyZXNzAQlzdHJUb0xpc3QBBF9zdHIDCQAAAgUEX3N0cgIABQNuaWwJALUJAgUEX3N0cgIBLAELY29vcmRpbmF0b3IACQETdmFsdWVPckVycm9yTWVzc2FnZQIJAKYIAQkBE3ZhbHVlT3JFcnJvck1lc3NhZ2UCCQCdCAIFBHRoaXMFFGtfY29vcmRpbmF0b3JBZGRyZXNzAhZDb29yZGluYXRvciBub3Qgc2V0IEhDAhtDb29yZGluYXRvciBhZGRyZXNzIGludmFsaWQBDGFkbWluQWRkcmVzcwAJAKYIAQkBE3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DYBAEIBQJ0eAJpZAcJAAIBAi51bmFibGUgdG8gdmVyaWZ5OiBhZG1pbiBub3Qgc2V0IGluIGNvb3JkaW5hdG9yCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACAUCdHgPc2VuZGVyUHVibGljS2V5xvfUZg==", "height": 2578924, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3gppVQdkxs4JQoUz1Pugiossuqwgzd6zPsimBXELqJE4 Next: 8mZhCBvuWh1Eu1Ej8vzsBY3unMYWq3ikUP6VEnTbWCaa Diff:
OldNewDifferences
6363 if ((doAckRewardsVault == doAckRewardsVault))
6464 then {
6565 let amms = strToList(_payFunding)
66- func compute (_acc,_amm) = {
67- let doPayFunding = invoke(addressFromStringValue(_amm), "payFunding", nil, nil)
66+ func compute (_acc,_ammData) = {
67+ let parts = split(_ammData, "@")
68+ let amm = parts[0]
69+ let priceUpdate = if ((size(parts) > 1))
70+ then parts[1]
71+ else ""
72+ let doPayFunding = invoke(addressFromStringValue(amm), "payFunding", [priceUpdate], nil)
6873 if ((doPayFunding == doPayFunding))
6974 then _acc
7075 else throw("Strict value is not equal to itself.")
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let k_initialized = "k_initialized"
55
66 let k_coordinatorAddress = "k_coordinatorAddress"
77
88 let k_staking_address = "k_staking_address"
99
1010 let k_farming_address = "k_farming_address"
1111
1212 let k_vault_address = "k_vault_address"
1313
1414 let k_admin_address = "k_admin_address"
1515
1616 func strToList (_str) = if ((_str == ""))
1717 then nil
1818 else split(_str, ",")
1919
2020
2121 func coordinator () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(this, k_coordinatorAddress), "Coordinator not set HC")), "Coordinator address invalid")
2222
2323
2424 func adminAddress () = addressFromString(valueOrErrorMessage(getString(coordinator(), k_admin_address), "Admin address not set"))
2525
2626
2727 func stakingAddress () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(coordinator(), k_staking_address), "Staking address not set")), "Staking address invalid")
2828
2929
3030 func farmingAddress () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(coordinator(), k_farming_address), "Farming address not set")), "Farming address invalid")
3131
3232
3333 func vaultAddress () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(coordinator(), k_vault_address), "Vault address not set")), "Vault address invalid")
3434
3535
3636 func initialized () = valueOrElse(getBoolean(this, k_initialized), false)
3737
3838
3939 @Callable(i)
4040 func initialize (_coordinator) = if (if (initialized())
4141 then true
4242 else (i.caller != this))
4343 then throw("Unable to initialize")
4444 else [StringEntry(k_coordinatorAddress, toString(addressFromStringValue(_coordinator))), BooleanEntry(k_initialized, true)]
4545
4646
4747
4848 @Callable(i)
4949 func performHousekeeping (_vault,_farming,_staking,_payFunding) = {
5050 let doAckRewardsStaking = if (_staking)
5151 then invoke(stakingAddress(), "ackRewards", nil, nil)
5252 else nil
5353 if ((doAckRewardsStaking == doAckRewardsStaking))
5454 then {
5555 let doAckRewardsFarming = if (_farming)
5656 then invoke(farmingAddress(), "ackRewards", nil, nil)
5757 else nil
5858 if ((doAckRewardsFarming == doAckRewardsFarming))
5959 then {
6060 let doAckRewardsVault = if (_vault)
6161 then invoke(vaultAddress(), "ackRewards", nil, nil)
6262 else nil
6363 if ((doAckRewardsVault == doAckRewardsVault))
6464 then {
6565 let amms = strToList(_payFunding)
66- func compute (_acc,_amm) = {
67- let doPayFunding = invoke(addressFromStringValue(_amm), "payFunding", nil, nil)
66+ func compute (_acc,_ammData) = {
67+ let parts = split(_ammData, "@")
68+ let amm = parts[0]
69+ let priceUpdate = if ((size(parts) > 1))
70+ then parts[1]
71+ else ""
72+ let doPayFunding = invoke(addressFromStringValue(amm), "payFunding", [priceUpdate], nil)
6873 if ((doPayFunding == doPayFunding))
6974 then _acc
7075 else throw("Strict value is not equal to itself.")
7176 }
7277
7378 let $l = amms
7479 let $s = size($l)
7580 let $acc0 = nil
7681 func $f0_1 ($a,$i) = if (($i >= $s))
7782 then $a
7883 else compute($a, $l[$i])
7984
8085 func $f0_2 ($a,$i) = if (($i >= $s))
8186 then $a
8287 else throw("List size exceeds 20")
8388
8489 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
8590 }
8691 else throw("Strict value is not equal to itself.")
8792 }
8893 else throw("Strict value is not equal to itself.")
8994 }
9095 else throw("Strict value is not equal to itself.")
9196 }
9297
9398
9499 @Verifier(tx)
95100 func verify () = {
96101 let coordinatorStr = getString(this, k_coordinatorAddress)
97102 if (isDefined(coordinatorStr))
98103 then {
99104 let admin = getString(addressFromStringValue(value(coordinatorStr)), k_admin_address)
100105 if (isDefined(admin))
101106 then valueOrElse(getBoolean(addressFromStringValue(value(admin)), ((("status_" + toString(this)) + "_") + toBase58String(tx.id))), false)
102107 else throw("unable to verify: admin not set in coordinator")
103108 }
104109 else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
105110 }
106111

github/deemru/w8io/169f3d6 
39.17 ms