tx · BWSrYbV69N6nEcxfTrHbC4ydijRhgLh4SEBn29tsdFSJ 3MtEi5vvwnSsHxTQh7L1tN1TqUWDzZGotZV: -0.00200000 Waves 2023.04.25 22:50 [2550512] smart account 3MtEi5vvwnSsHxTQh7L1tN1TqUWDzZGotZV > SELF 0.00000000 Waves
{ "type": 13, "id": "BWSrYbV69N6nEcxfTrHbC4ydijRhgLh4SEBn29tsdFSJ", "fee": 200000, "feeAssetId": null, "timestamp": 1682452228725, "version": 1, "sender": "3MtEi5vvwnSsHxTQh7L1tN1TqUWDzZGotZV", "senderPublicKey": "5vatV6DGBbB26P6sid7YsMydWWke53vKCsAM2akKuXXm", "proofs": [ "2jKBsptdMPmdU9M3YMXhxtAQPtAUJFXaRxxqWwtyJPmrycPwawtpxkVwqxD3zuiy7iU473D3M3zzvgbazVtQuvtF" ], "script": "base64:BgIECAISAAUACHJlY2VpdmVyCQEHQWRkcmVzcwEBGgFUGka9OmWcMzmsn6UEd761d70UF0omV1ldAAFyCQEHQWRkcmVzcwEBGgFU0bzJU35CJJvLVpUtc7pcARyHATi9z6uUAAFzCQEHQWRkcmVzcwEBGgFUBdDRB9MyA3sY2aNrXhTUhmsB2dXLhEFoAAF3CQEHQWRkcmVzcwEBGgFUj/pdlJyLAVLnyQL4NA8O85EC0Jc5XAYNAQxnZXRJbnRPclplcm8BA2tleQkBC3ZhbHVlT3JFbHNlAgkAnwgBBQNrZXkAAAEBaQEEdGVzdAADCQECIT0CCAUBaQZjYWxsZXIFBHRoaXMJAAIBAgpvbmx5IGFkbWluBAFlCQCkAwEJARFAZXh0ck5hdGl2ZSgxMDUwKQIFAXMJAKwCAgIeU0lHTkVEX0VWRU5UX0VYRUNVVE9SX18xMDAwMV9fCQCkAwEJAGUCCQERQGV4dHJOYXRpdmUoMTA1MCkCBQFzAiJTSUdORURfRVZFTlRfRVhFQ1VUT1JfXzEwMDAxX19TSVpFAAEEAWQJALUJAgkBEUBleHRyTmF0aXZlKDEwNTMpAgUBdwkArA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zIG5vdCBlcXVhbCB0byBpdHNlbGYuAB4i5Fk=", "chainId": 84, "height": 2550512, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8HqPG1CBpekyqNYrU4MJX14oNBSxqg8cSdWFpGhqvgRg Next: 74ASc55Ga7bRAtFT6SxUoKdEvTA9spQbSJX8qcDMHzTv Diff:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let caller = Address(base58'3MyvTz5YdGcLnsDW9EscXaAiN5CgHfRaGQ3') | |
5 | - | ||
6 | 4 | let receiver = Address(base58'3MrK25xAkfYJt1VYu9ZVMmQhZD8XwrT1DgQ') | |
7 | 5 | ||
8 | 6 | let r = Address(base58'3N935A8AAp2u1isbYYqX3Kp9prZmHF6kNps') | |
15 | 13 | ||
16 | 14 | ||
17 | 15 | @Callable(i) | |
18 | - | func test () = if ((i.caller != | |
16 | + | func test () = if ((i.caller != this)) | |
19 | 17 | then throw("only admin") | |
20 | 18 | else { | |
21 | 19 | let e = toString(getIntegerValue(s, ("SIGNED_EVENT_EXECUTOR__10001__" + toString((getIntegerValue(s, "SIGNED_EVENT_EXECUTOR__10001__SIZE") - 1))))) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let caller = Address(base58'3MyvTz5YdGcLnsDW9EscXaAiN5CgHfRaGQ3') | |
5 | - | ||
6 | 4 | let receiver = Address(base58'3MrK25xAkfYJt1VYu9ZVMmQhZD8XwrT1DgQ') | |
7 | 5 | ||
8 | 6 | let r = Address(base58'3N935A8AAp2u1isbYYqX3Kp9prZmHF6kNps') | |
9 | 7 | ||
10 | 8 | let s = Address(base58'3MpSqJhv64PR2m7Ywctv1Mp2Kjt3EUk3CSK') | |
11 | 9 | ||
12 | 10 | let w = Address(base58'3N33NL4BGxFEEiXKgnENVRDiE3RwkYmaNmS') | |
13 | 11 | ||
14 | 12 | func getIntOrZero (key) = valueOrElse(getInteger(key), 0) | |
15 | 13 | ||
16 | 14 | ||
17 | 15 | @Callable(i) | |
18 | - | func test () = if ((i.caller != | |
16 | + | func test () = if ((i.caller != this)) | |
19 | 17 | then throw("only admin") | |
20 | 18 | else { | |
21 | 19 | let e = toString(getIntegerValue(s, ("SIGNED_EVENT_EXECUTOR__10001__" + toString((getIntegerValue(s, "SIGNED_EVENT_EXECUTOR__10001__SIZE") - 1))))) | |
22 | 20 | let d = split(getStringValue(w, ("WAVES_EVENT__" + e)), "__") | |
23 | 21 | let args = split(d[5], "####") | |
24 | 22 | let inv = invoke(r, "execute", [d[3], d[4], args, parseIntValue(d[0]), parseIntValue(d[1]), parseIntValue(d[2]), d[6], toBase58String((fromBase58String(getStringValue(s, ("R_SIGMA__10001__" + e))) + fromBase58String(getStringValue(s, ("S_SIGMA__10001__" + e)))))], nil) | |
25 | 23 | if ((inv == inv)) | |
26 | 24 | then { | |
27 | 25 | let minterAddress = addressFromStringValue(args[1]) | |
28 | 26 | let assetStr = getStringValue(minterAddress, "ASSET") | |
29 | 27 | let asset = fromBase58String(assetStr) | |
30 | 28 | let balance = assetBalance(this, asset) | |
31 | 29 | [ScriptTransfer(receiver, balance, asset), IntegerEntry(((("profit_" + assetStr) + "_") + toString(lastBlock.timestamp)), balance), IntegerEntry(("totalProfit_" + assetStr), (getIntOrZero(("totalProfit_" + assetStr)) + balance))] | |
32 | 30 | } | |
33 | 31 | else throw("Strict value is not equal to itself.") | |
34 | 32 | } | |
35 | 33 | ||
36 | 34 |
github/deemru/w8io/026f985 36.65 ms ◑