tx · HEXE2ZWAwh6hsDvp1GmimaQDJyBZBZ3DR4cGnFYPGz9c 3MusfsY6PqDh1YnF7YyTi5ffVT16Dm2bqf6: -0.01000000 Waves 2023.03.09 02:49 [2481785] smart account 3MusfsY6PqDh1YnF7YyTi5ffVT16Dm2bqf6 > SELF 0.00000000 Waves
{ "type": 13, "id": "HEXE2ZWAwh6hsDvp1GmimaQDJyBZBZ3DR4cGnFYPGz9c", "fee": 1000000, "feeAssetId": null, "timestamp": 1678319353801, "version": 2, "chainId": 84, "sender": "3MusfsY6PqDh1YnF7YyTi5ffVT16Dm2bqf6", "senderPublicKey": "GmYZFRssDr88KiZt3x4LsJ6qfqaTfMUycQTKZVdipUgS", "proofs": [ "5E4EpePVbroP5nc9fvqWC8dPdTcCySZq3L1NdHofWkTVhLa7ek5aTWz6JCFmVpSp6K57VsczvRmAGhDq4Up4kVPS" ], "script": "base64:BgImCAISBAoCCAESBAoCCAESBAoCGBgSBAoCCAgSAwoBCBIFCgMICAgDAAxvcHRpb25zX2FkZHIJAQdBZGRyZXNzAQEaAVRBW/gr9hfqKqHLxIrx+8e7siBhMf6HIMEABHRSVUIBIL+yNSxI/30uJ2QBhJluNs/7yveJ33oijdPH8O2ulNmbAAR0VVNEASCrJEpqtkJG69L843mwYbrDrmlXTVJ6ykUcp0AdEbApDgYBaQERcmVpc3N1ZUZvckRlcEFkZHICBXRva2VuCHF1YW50aXR5BAlhZG1pbkxpc3QEByRtYXRjaDAJAJ0IAgUMb3B0aW9uc19hZGRyAgphZG1pbl9saXN0AwkAAQIFByRtYXRjaDACBFVuaXQCBXVuc2V0AwkAAQIFByRtYXRjaDACBlN0cmluZwQBeAUHJG1hdGNoMAUBeAkAAgECC01hdGNoIGVycm9yBBBjYWxsZXJBZGRyZXNzU3RyCQClCAEIBQFpBmNhbGxlcgMJAQIhPQIFCWFkbWluTGlzdAIFdW5zZXQEBHRlc3QJAJ0IAgkBEUBleHRyTmF0aXZlKDEwNjIpAQUJYWRtaW5MaXN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F0Y2gwCQCdCAIFBHRoaXMJANgEAQgIBQFpBmNhbGxlcgVieXRlcwMJAAECBQckbWF0Y2gwAgZTdHJpbmcEBGhpc3QFByRtYXRjaDAFBGhpc3QCBXVuc2V0AwkBAiE9AgUNaXNLbm93bkNhbGxlcgIFdW5zZXQJAJQKAgkAzAgCCQELU3RyaW5nRW50cnkCCQDYBAEICAUBaQZjYWxsZXIFYnl0ZXMJAKwCAgkArAICCQCsAgIJAKwCAgUEbmFtZQIBfAUDaW5uAgF8BQRvZ3JuCQDMCAIJAQ5TY3JpcHRUcmFuc2ZlcgMIBQFpBmNhbGxlcgDAhD0FBHVuaXQJAMwIAgkBDlNjcmlwdFRyYW5zZmVyAwgFAWkGY2FsbGVyAMCEPQUEdFVTRAUDbmlsBQR1bml0CQACAQIVQ2FuIGJlIHVzZWQgb25seSBvbmNlAQJ0eAEGdmVyaWZ5AAQHJG1hdGNoMAUCdHgDCQABAgUHJG1hdGNoMAIPRGF0YVRyYW5zYWN0aW9uBANkdHgFByRtYXRjaDAHCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACAUCdHgPc2VuZGVyUHVibGljS2V5ixcXyw==", "height": 2481785, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8JmEHU2rJ9151yvKVymwrT8b6fWLRx6KJeapEwyc4oK Next: EbRNPMnmTWZrq7eC8DG36PnnaMVR3iyKPH7x4T1bbSe Diff:
Old | New | Differences | |
---|---|---|---|
38 | 38 | if ((l != "no admin")) | |
39 | 39 | then { | |
40 | 40 | let m = Reissue(fromBase58String(e), f, true) | |
41 | - | $Tuple2([m], (((((((("Reissue error for param: token =>" + e) + " quantity:") + toString(f)) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ".")) | |
41 | + | if ((m == m)) | |
42 | + | then $Tuple2([m], (((((((("Reissue error for param: token =>" + e) + " quantity:") + toString(f)) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ".")) | |
43 | + | else throw("Strict value is not equal to itself.") | |
42 | 44 | } | |
43 | 45 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
44 | 46 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = Address(base58'3MusfsY6PqDh1YnF7YyTi5ffVT16Dm2bqf6') | |
5 | 5 | ||
6 | 6 | let b = base58'DuJUjEZJWmpFUo3bubFX8tomUVitqZZNAPuhd6KWgJNE' | |
7 | 7 | ||
8 | 8 | let c = base58'CX4p6XcuSBUvv44r1avCqYka5PYAVzBK5hSXaT7maU85' | |
9 | 9 | ||
10 | 10 | @Callable(d) | |
11 | 11 | func reissueForDepAddr (e,f) = { | |
12 | 12 | let g = { | |
13 | 13 | let h = getString(a, "admin_list") | |
14 | 14 | if ($isInstanceOf(h, "Unit")) | |
15 | 15 | then "unset" | |
16 | 16 | else if ($isInstanceOf(h, "String")) | |
17 | 17 | then { | |
18 | 18 | let i = h | |
19 | 19 | i | |
20 | 20 | } | |
21 | 21 | else throw("Match error") | |
22 | 22 | } | |
23 | 23 | let j = toString(d.caller) | |
24 | 24 | if ((g != "unset")) | |
25 | 25 | then { | |
26 | 26 | let k = getString(addressFromStringValue(g), j) | |
27 | 27 | let l = { | |
28 | 28 | let h = k | |
29 | 29 | if ($isInstanceOf(h, "String")) | |
30 | 30 | then { | |
31 | 31 | let i = h | |
32 | 32 | i | |
33 | 33 | } | |
34 | 34 | else if ($isInstanceOf(h, "Unit")) | |
35 | 35 | then "no admin" | |
36 | 36 | else throw("Match error") | |
37 | 37 | } | |
38 | 38 | if ((l != "no admin")) | |
39 | 39 | then { | |
40 | 40 | let m = Reissue(fromBase58String(e), f, true) | |
41 | - | $Tuple2([m], (((((((("Reissue error for param: token =>" + e) + " quantity:") + toString(f)) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ".")) | |
41 | + | if ((m == m)) | |
42 | + | then $Tuple2([m], (((((((("Reissue error for param: token =>" + e) + " quantity:") + toString(f)) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ".")) | |
43 | + | else throw("Strict value is not equal to itself.") | |
42 | 44 | } | |
43 | 45 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
44 | 46 | } | |
45 | 47 | else throw("Unset admin list") | |
46 | 48 | } | |
47 | 49 | ||
48 | 50 | ||
49 | 51 | ||
50 | 52 | @Callable(d) | |
51 | 53 | func reissueTokens (e,f) = { | |
52 | 54 | let g = { | |
53 | 55 | let h = getString(a, "admin_list") | |
54 | 56 | if ($isInstanceOf(h, "Unit")) | |
55 | 57 | then "unset" | |
56 | 58 | else if ($isInstanceOf(h, "String")) | |
57 | 59 | then { | |
58 | 60 | let i = h | |
59 | 61 | i | |
60 | 62 | } | |
61 | 63 | else throw("Match error") | |
62 | 64 | } | |
63 | 65 | let j = toString(d.caller) | |
64 | 66 | if ((g != "unset")) | |
65 | 67 | then { | |
66 | 68 | let k = getString(addressFromStringValue(g), j) | |
67 | 69 | let l = { | |
68 | 70 | let h = k | |
69 | 71 | if ($isInstanceOf(h, "String")) | |
70 | 72 | then { | |
71 | 73 | let i = h | |
72 | 74 | i | |
73 | 75 | } | |
74 | 76 | else if ($isInstanceOf(h, "Unit")) | |
75 | 77 | then "no admin" | |
76 | 78 | else throw("Match error") | |
77 | 79 | } | |
78 | 80 | if ((l != "no admin")) | |
79 | 81 | then { | |
80 | 82 | let m = Reissue(fromBase58String(e), f, true) | |
81 | 83 | $Tuple2([m], (((((((("Reissue error for param: token => " + e) + ", quantity:") + toString(f)) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ".")) | |
82 | 84 | } | |
83 | 85 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
84 | 86 | } | |
85 | 87 | else throw("Unset admin list") | |
86 | 88 | } | |
87 | 89 | ||
88 | 90 | ||
89 | 91 | ||
90 | 92 | @Callable(d) | |
91 | 93 | func setOptions (n,o) = { | |
92 | 94 | let p = size(n) | |
93 | 95 | if ((100 >= p)) | |
94 | 96 | then { | |
95 | 97 | let g = { | |
96 | 98 | let h = getString(this, "admin_list") | |
97 | 99 | if ($isInstanceOf(h, "Unit")) | |
98 | 100 | then "unset" | |
99 | 101 | else if ($isInstanceOf(h, "String")) | |
100 | 102 | then { | |
101 | 103 | let i = h | |
102 | 104 | i | |
103 | 105 | } | |
104 | 106 | else throw("Match error") | |
105 | 107 | } | |
106 | 108 | func q (r,s) = { | |
107 | 109 | let t = r | |
108 | 110 | let u = t._1 | |
109 | 111 | let v = t._2 | |
110 | 112 | $Tuple2((u :+ StringEntry(n[v], s)), (v + 1)) | |
111 | 113 | } | |
112 | 114 | ||
113 | 115 | let w = { | |
114 | 116 | let x = o | |
115 | 117 | let y = size(x) | |
116 | 118 | let z = $Tuple2(nil, 0) | |
117 | 119 | func A (B,C) = if ((C >= y)) | |
118 | 120 | then B | |
119 | 121 | else q(B, x[C]) | |
120 | 122 | ||
121 | 123 | func D (B,C) = if ((C >= y)) | |
122 | 124 | then B | |
123 | 125 | else throw("List size exceeds 100") | |
124 | 126 | ||
125 | 127 | D(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(A(z, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
126 | 128 | } | |
127 | 129 | let j = toString(d.caller) | |
128 | 130 | if ((g != "unset")) | |
129 | 131 | then { | |
130 | 132 | let k = getString(addressFromStringValue(g), j) | |
131 | 133 | let l = { | |
132 | 134 | let h = k | |
133 | 135 | if ($isInstanceOf(h, "String")) | |
134 | 136 | then { | |
135 | 137 | let i = h | |
136 | 138 | i | |
137 | 139 | } | |
138 | 140 | else if ($isInstanceOf(h, "Unit")) | |
139 | 141 | then "no admin" | |
140 | 142 | else throw("Match error") | |
141 | 143 | } | |
142 | 144 | func E (F) = { | |
143 | 145 | let G = split(F, "|") | |
144 | 146 | StringEntry(G[0], G[1]) | |
145 | 147 | } | |
146 | 148 | ||
147 | 149 | if ((l != "no admin")) | |
148 | 150 | then w | |
149 | 151 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
150 | 152 | } | |
151 | 153 | else throw("Unset admin list") | |
152 | 154 | } | |
153 | 155 | else throw("The number of list elements must not exceed 100") | |
154 | 156 | } | |
155 | 157 | ||
156 | 158 | ||
157 | 159 | ||
158 | 160 | @Callable(d) | |
159 | 161 | func setOption (H,I) = { | |
160 | 162 | let g = { | |
161 | 163 | let h = getString(this, "admin_list") | |
162 | 164 | if ($isInstanceOf(h, "Unit")) | |
163 | 165 | then "unset" | |
164 | 166 | else if ($isInstanceOf(h, "String")) | |
165 | 167 | then { | |
166 | 168 | let i = h | |
167 | 169 | i | |
168 | 170 | } | |
169 | 171 | else throw("Match error") | |
170 | 172 | } | |
171 | 173 | let j = toString(d.caller) | |
172 | 174 | if ((g != "unset")) | |
173 | 175 | then { | |
174 | 176 | let k = getString(addressFromStringValue(g), j) | |
175 | 177 | let l = { | |
176 | 178 | let h = k | |
177 | 179 | if ($isInstanceOf(h, "String")) | |
178 | 180 | then { | |
179 | 181 | let i = h | |
180 | 182 | i | |
181 | 183 | } | |
182 | 184 | else if ($isInstanceOf(h, "Unit")) | |
183 | 185 | then "no admin" | |
184 | 186 | else throw("Match error") | |
185 | 187 | } | |
186 | 188 | if ((l != "no admin")) | |
187 | 189 | then $Tuple2([StringEntry(H, I)], unit) | |
188 | 190 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
189 | 191 | } | |
190 | 192 | else throw("Unset admin list") | |
191 | 193 | } | |
192 | 194 | ||
193 | 195 | ||
194 | 196 | ||
195 | 197 | @Callable(d) | |
196 | 198 | func delOption (H) = { | |
197 | 199 | let g = { | |
198 | 200 | let h = getString(this, "admin_list") | |
199 | 201 | if ($isInstanceOf(h, "Unit")) | |
200 | 202 | then "unset" | |
201 | 203 | else if ($isInstanceOf(h, "String")) | |
202 | 204 | then { | |
203 | 205 | let i = h | |
204 | 206 | i | |
205 | 207 | } | |
206 | 208 | else throw("Match error") | |
207 | 209 | } | |
208 | 210 | let j = toString(d.caller) | |
209 | 211 | if ((g != "unset")) | |
210 | 212 | then { | |
211 | 213 | let k = getString(addressFromStringValue(g), j) | |
212 | 214 | let l = { | |
213 | 215 | let h = k | |
214 | 216 | if ($isInstanceOf(h, "String")) | |
215 | 217 | then { | |
216 | 218 | let i = h | |
217 | 219 | i | |
218 | 220 | } | |
219 | 221 | else if ($isInstanceOf(h, "Unit")) | |
220 | 222 | then "no admin" | |
221 | 223 | else throw("Match error") | |
222 | 224 | } | |
223 | 225 | if ((l != "no admin")) | |
224 | 226 | then $Tuple2([DeleteEntry(H)], unit) | |
225 | 227 | else throw((((((("You not admin: " + g) + ", isAdmin: ") + l) + ", callerAddressStr: ") + j) + ", ")) | |
226 | 228 | } | |
227 | 229 | else throw("Unset admin list") | |
228 | 230 | } | |
229 | 231 | ||
230 | 232 | ||
231 | 233 | ||
232 | 234 | @Callable(d) | |
233 | 235 | func regProvider (J,K,L) = { | |
234 | 236 | let M = { | |
235 | 237 | let h = getString(this, toBase58String(d.caller.bytes)) | |
236 | 238 | if ($isInstanceOf(h, "String")) | |
237 | 239 | then { | |
238 | 240 | let N = h | |
239 | 241 | N | |
240 | 242 | } | |
241 | 243 | else "unset" | |
242 | 244 | } | |
243 | 245 | if ((M != "unset")) | |
244 | 246 | then $Tuple2([StringEntry(toBase58String(d.caller.bytes), ((((J + "|") + K) + "|") + L)), ScriptTransfer(d.caller, 1000000, unit), ScriptTransfer(d.caller, 1000000, c)], unit) | |
245 | 247 | else throw("Can be used only once") | |
246 | 248 | } | |
247 | 249 | ||
248 | 250 | ||
249 | 251 | @Verifier(O) | |
250 | 252 | func P () = { | |
251 | 253 | let h = O | |
252 | 254 | if ($isInstanceOf(h, "DataTransaction")) | |
253 | 255 | then { | |
254 | 256 | let Q = h | |
255 | 257 | false | |
256 | 258 | } | |
257 | 259 | else sigVerify(O.bodyBytes, O.proofs[0], O.senderPublicKey) | |
258 | 260 | } | |
259 | 261 |
github/deemru/w8io/169f3d6 534.79 ms ◑