tx · HPFxudM7jYSTqgZrQqtU1zz4bkMHkowev5niTLgS6qQx

3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac:  -0.03700000 Waves

2023.07.26 23:12 [2683287] smart account 3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac > SELF 0.00000000 Waves

{ "type": 13, "id": "HPFxudM7jYSTqgZrQqtU1zz4bkMHkowev5niTLgS6qQx", "fee": 3700000, "feeAssetId": null, "timestamp": 1690402379230, "version": 2, "chainId": 84, "sender": "3MwC75rhWzLpeEwLGSnF3ftHNh4fGBU48Ac", "senderPublicKey": "9yW1Jko9uspFMWxZL7MsaEnTH66KnoCqj69k36PKqZq3", "proofs": [ "2W13TMCgF1ghjytNv2xDgKw1u9hD21GDxF1kGvgXUDx1NUWLkNSkXLXXZKmPiKC1NZkb3wwJetGkMhyGfabRGQgT" ], "script": "base64:BgIQCAISAwoBCBIHCgUEBAQICA0ADWtfaW5pdGlhbGl6ZWQCDWtfaW5pdGlhbGl6ZWQAFGtfY29vcmRpbmF0b3JBZGRyZXNzAhRrX2Nvb3JkaW5hdG9yQWRkcmVzcwARa19zdGFraW5nX2FkZHJlc3MCEWtfc3Rha2luZ19hZGRyZXNzABFrX2Zhcm1pbmdfYWRkcmVzcwIRa19mYXJtaW5nX2FkZHJlc3MAD2tfdmF1bHRfYWRkcmVzcwIPa192YXVsdF9hZGRyZXNzAA9rX2FkbWluX2FkZHJlc3MCD2tfYWRtaW5fYWRkcmVzcwEJc3RyVG9MaXN0AQRfc3RyAwkAAAIFBF9zdHICAAUDbmlsCQC8CQIFBF9zdHICASwBC2Nvb3JkaW5hdG9yAAkBE3ZhbHVlT3JFcnJvck1lc3NhZ2UCCQCmCAEJARN2YWx1ZU9yRXJyb3JNZXNzYWdlAgkAnQgCBQR0aGlzBRRrX2Nvb3JkaW5hdG9yQWRkcmVzcwIWQ29vcmRpbmF0b3Igbm90IHNldCBIQwIbQ29vcmRpbmF0b3IgYWRkcmVzcyBpbnZhbGl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QEFJGYxXzECBQUkYWNjMAAAAAEAAgADAAQABQMJAAACBQxkb0NhbGxWYXVsdHMFDGRvQ2FsbFZhdWx0cwUDbmlsCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAQJ0eAEGdmVyaWZ5AAQOY29vcmRpbmF0b3JTdHIJAJ0IAgUEdGhpcwUUa19jb29yZGluYXRvckFkZHJlc3MDCQEJaXNEZWZpbmVkAQUOY29vcmRpbmF0b3JTdHIEBWFkbWluCQCdCAIJARFAZXh0ck5hdGl2ZSgxMDYyKQEJAQV2YWx1ZQEFDmNvb3JkaW5hdG9yU3RyBQ9rX2FkbWluX2FkZHJlc3MDCQEJaXNEZWZpbmVkAQUFYWRtaW4JAQt2YWx1ZU9yRWxzZQIJAJsIAgkBEUBleHRyTmF0aXZlKDEwNjIpAQkBBXZhbHVlAQUFYWRtaW4JAKwCAgkArAICCQCsAgICB3N0YXR1c18JAKUIAQUEdGhpcwIBXwkA2AQBCAUCdHgCaWQHCQACAQIudW5hYmxlIHRvIHZlcmlmeTogYWRtaW4gbm90IHNldCBpbiBjb29yZGluYXRvcgkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tleSAUT58=", "height": 2683287, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4JabVZVdZKTP36r9Y8YA5bTK8H3zoauHqRXUoKWJcDD6 Next: none Diff:
OldNewDifferences
1515
1616 func strToList (_str) = if ((_str == ""))
1717 then nil
18- else split(_str, ",")
18+ else split_4C(_str, ",")
1919
2020
2121 func coordinator () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(this, k_coordinatorAddress), "Coordinator not set HC")), "Coordinator address invalid")
8585
8686 func $f0_2 ($a,$i) = if (($i >= $s))
8787 then $a
88- else throw("List size exceeds 5")
88+ else throw("List size exceeds 10")
8989
90- $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5)
90+ $f0_2($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)
9191 }
9292 if ((doCallAmms == doCallAmms))
9393 then {
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
18- else split(_str, ",")
18+ else split_4C(_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,_spotVaults) = {
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)
6666 func compute (_acc,_ammData) = {
6767 let parts = split_4C(_ammData, "@")
6868 let amm = parts[0]
6969 let priceUpdate = if ((size(parts) > 1))
7070 then parts[1]
7171 else ""
7272 let doPayFunding = invoke(addressFromStringValue(amm), "payFunding", [priceUpdate], nil)
7373 if ((doPayFunding == doPayFunding))
7474 then _acc
7575 else throw("Strict value is not equal to itself.")
7676 }
7777
7878 let doCallAmms = {
7979 let $l = amms
8080 let $s = size($l)
8181 let $acc0 = nil
8282 func $f0_1 ($a,$i) = if (($i >= $s))
8383 then $a
8484 else compute($a, $l[$i])
8585
8686 func $f0_2 ($a,$i) = if (($i >= $s))
8787 then $a
88- else throw("List size exceeds 5")
88+ else throw("List size exceeds 10")
8989
90- $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5)
90+ $f0_2($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)
9191 }
9292 if ((doCallAmms == doCallAmms))
9393 then {
9494 let vaults = strToList(_spotVaults)
9595 func compute2 (_acc,_vault) = {
9696 let doPayFunding = invoke(addressFromStringValue(_vault), "ackRewards", nil, nil)
9797 if ((doPayFunding == doPayFunding))
9898 then _acc
9999 else throw("Strict value is not equal to itself.")
100100 }
101101
102102 let doCallVaults = {
103103 let $l = vaults
104104 let $s = size($l)
105105 let $acc0 = nil
106106 func $f1_1 ($a,$i) = if (($i >= $s))
107107 then $a
108108 else compute2($a, $l[$i])
109109
110110 func $f1_2 ($a,$i) = if (($i >= $s))
111111 then $a
112112 else throw("List size exceeds 5")
113113
114114 $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5)
115115 }
116116 if ((doCallVaults == doCallVaults))
117117 then nil
118118 else throw("Strict value is not equal to itself.")
119119 }
120120 else throw("Strict value is not equal to itself.")
121121 }
122122 else throw("Strict value is not equal to itself.")
123123 }
124124 else throw("Strict value is not equal to itself.")
125125 }
126126 else throw("Strict value is not equal to itself.")
127127 }
128128
129129
130130 @Verifier(tx)
131131 func verify () = {
132132 let coordinatorStr = getString(this, k_coordinatorAddress)
133133 if (isDefined(coordinatorStr))
134134 then {
135135 let admin = getString(addressFromStringValue(value(coordinatorStr)), k_admin_address)
136136 if (isDefined(admin))
137137 then valueOrElse(getBoolean(addressFromStringValue(value(admin)), ((("status_" + toString(this)) + "_") + toBase58String(tx.id))), false)
138138 else throw("unable to verify: admin not set in coordinator")
139139 }
140140 else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
141141 }
142142

github/deemru/w8io/026f985 
28.68 ms