tx · HY2sn8wwEwNKgiUNvRnAM8xrbXAjHwBviFTHw9tncSVC 3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h: -0.01300000 Waves 2024.02.12 14:41 [2972991] smart account 3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h > SELF 0.00000000 Waves
{ "type": 13, "id": "HY2sn8wwEwNKgiUNvRnAM8xrbXAjHwBviFTHw9tncSVC", "fee": 1300000, "feeAssetId": null, "timestamp": 1707738085318, "version": 2, "chainId": 84, "sender": "3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h", "senderPublicKey": "3z8Q6Zu3KppVmn6fJJvrLc1Wo3krVHSvfaNcerm82md2", "proofs": [ "5BQAMQaS7GLVDYqb2YaSJjQAmwe9MwtGcoNXuKpeXEthybi4zX7qUYiSzgF1pvMKuBfvMU57gJZk796vvHGUh6qc" ], "script": "base64:BgIvCAISAwoBARIDCgEIEgMKAQgSBAoCCAgSAwoBCBIECgIIARIECgIIARIDCgEBEgAlAAxjb250cmFjdEZpbGUCEWwybXBfbGVhc2luZy5yaWRlAANTRVACAl9fAAZzY2FsZTgAgMLXLwEIdGhyb3dFcnIBA21zZwkAAgEJAKwCAgkArAICBQxjb250cmFjdEZpbGUCAjogBQNtc2cACmtleUFzc2V0SWQJALkJAgkAzAgCAgIlcwkAzAgCAgdhc3NldElkBQNuaWwFA1NFUAARa2V5UGVyaW9kT2Zmc2V0SWQJALkJAgkAzAgCAgIlcwkAzAgCAghvZmZzZXRJZAUDbmlsBQNTRVAAFWtleVBlcmlvZE9mZnNldEhlaWdodAkAuQkCCQDMCAICAiVzCQDMCAICDG9mZnNldEhlaWdodAUDbmlsBQNTRVAAD2tleVBlcmlvZExlbmd0aAkAuQkCCQDMCAICAiVzCQDMCAICDHBlcmlvZExlbmd0aAUDbmlsBQNTRVAADnBlcmlvZE9mZnNldElkCQELdmFsdWVPckVsc2UCCQCaCAIFBHRoaXMFEWtleVBlcmlvZE9mZnNldElkAAAADHBlcmlvZ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AQLdXNlckFkZHJlc3MJAKUIAQgFAWkGY2FsbGVyCQEXZ2V0Q2xhaW1VbmxvY2tlZEFjdGlvbnMCBQt1c2VyQWRkcmVzcwUGYW1vdW50AWkBCGNsYWltQWxsAAQLdXNlckFkZHJlc3MJAKUIAQgFAWkGY2FsbGVyBA0kdDAxMzM1NDEzNDE0CQEVZ2V0VXNlclRvQ2xhaW1CYWxhbmNlAQULdXNlckFkZHJlc3MEB3RvQ2xhaW0IBQ0kdDAxMzM1NDEzNDE0Al8xBAh0b1VubG9jawgFDSR0MDEzMzU0MTM0MTQCXzIJARdnZXRDbGFpbVVubG9ja2VkQWN0aW9ucwIFC3VzZXJBZGRyZXNzBQd0b0NsYWltANEpKk4=", "height": 2972991, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 7gShWbxXeGEHPD7bhARcBjud47w6DTRcPddq47HYDjSp Next: FnM5niybaRHAzGUDCTqcCXp5YmWFPANhmr39Q2pQHZPV Diff:
Old | New | Differences | |
---|---|---|---|
306 | 306 | } | |
307 | 307 | ||
308 | 308 | ||
309 | + | func aJ () = $Tuple3(height, n, o) | |
310 | + | ||
311 | + | ||
309 | 312 | @Callable(ah) | |
310 | 313 | func setNewPeriodLength (aF) = aE(aF) | |
311 | 314 | ||
312 | 315 | ||
313 | 316 | ||
314 | 317 | @Callable(ah) | |
315 | - | func getUserData (s) = { | |
316 | - | let aJ = W(s) | |
317 | - | let U = aJ._1 | |
318 | - | let V = aJ._2 | |
318 | + | func getNodeDataREADONLY (q) = { | |
319 | + | let aK = F(q) | |
320 | + | let aL = aK._1 | |
321 | + | let D = aK._2 | |
322 | + | let aM = aJ() | |
323 | + | let Y = aM._1 | |
324 | + | let Z = aM._2 | |
325 | + | $Tuple2(nil, $Tuple4(aL, D, Y, Z)) | |
326 | + | } | |
327 | + | ||
328 | + | ||
329 | + | ||
330 | + | @Callable(ah) | |
331 | + | func getUserDataREADONLY (s) = { | |
332 | + | let aN = W(s) | |
333 | + | let U = aN._1 | |
334 | + | let V = aN._2 | |
319 | 335 | let ac = aa(s) | |
320 | - | $Tuple2(nil, $ | |
336 | + | $Tuple2(nil, $Tuple4(U, V, aJ(), ac)) | |
321 | 337 | } | |
322 | 338 | ||
323 | 339 | ||
336 | 352 | ||
337 | 353 | ||
338 | 354 | @Callable(ah) | |
339 | - | func stakeFromUnlocked (q, | |
355 | + | func stakeFromUnlocked (q,aO) = { | |
340 | 356 | let s = toString(ah.caller) | |
341 | - | az(q, s, | |
357 | + | az(q, s, aO) | |
342 | 358 | } | |
343 | 359 | ||
344 | 360 | ||
345 | 361 | ||
346 | 362 | @Callable(ah) | |
347 | - | func unstake (q, | |
363 | + | func unstake (q,aO) = { | |
348 | 364 | let s = toString(ah.caller) | |
349 | - | ao(q, s, | |
365 | + | ao(q, s, aO) | |
350 | 366 | } | |
351 | 367 | ||
352 | 368 | ||
353 | 369 | ||
354 | 370 | @Callable(ah) | |
355 | - | func claim ( | |
371 | + | func claim (aO) = { | |
356 | 372 | let s = toString(ah.caller) | |
357 | - | av(s, | |
373 | + | av(s, aO) | |
358 | 374 | } | |
359 | 375 | ||
360 | 376 | ||
362 | 378 | @Callable(ah) | |
363 | 379 | func claimAll () = { | |
364 | 380 | let s = toString(ah.caller) | |
365 | - | let | |
366 | - | let U = | |
367 | - | let V = | |
381 | + | let aP = W(s) | |
382 | + | let U = aP._1 | |
383 | + | let V = aP._2 | |
368 | 384 | av(s, U) | |
369 | 385 | } | |
370 | 386 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "l2mp_leasing.ride" | |
5 | 5 | ||
6 | 6 | let b = "__" | |
7 | 7 | ||
8 | 8 | let c = 100000000 | |
9 | 9 | ||
10 | 10 | func d (e) = throw(((a + ": ") + e)) | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | let f = makeString(["%s", "assetId"], b) | |
14 | 14 | ||
15 | 15 | let g = makeString(["%s", "offsetId"], b) | |
16 | 16 | ||
17 | 17 | let h = makeString(["%s", "offsetHeight"], b) | |
18 | 18 | ||
19 | 19 | let i = makeString(["%s", "periodLength"], b) | |
20 | 20 | ||
21 | 21 | let j = valueOrElse(getInteger(this, g), 0) | |
22 | 22 | ||
23 | 23 | let k = valueOrElse(getInteger(this, i), 10000) | |
24 | 24 | ||
25 | 25 | let l = valueOrElse(getInteger(this, h), -1) | |
26 | 26 | ||
27 | 27 | let m = if (if ((height > l)) | |
28 | 28 | then (l != -1) | |
29 | 29 | else false) | |
30 | 30 | then (((height - l) / k) + j) | |
31 | 31 | else max([0, (j - 1)]) | |
32 | 32 | ||
33 | 33 | let n = (l + ((m - j) * k)) | |
34 | 34 | ||
35 | 35 | let o = (n + k) | |
36 | 36 | ||
37 | 37 | func p (q) = makeString(["%s", q], b) | |
38 | 38 | ||
39 | 39 | ||
40 | 40 | func r (s) = makeString(["%s%s", "userLeasingNodeList", s], b) | |
41 | 41 | ||
42 | 42 | ||
43 | 43 | func t (s,q) = makeString(["%s%s", q, s], b) | |
44 | 44 | ||
45 | 45 | ||
46 | 46 | func u (s) = makeString(["%s%s", "toClaim", s], b) | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | let v = valueOrElse(getString(this, f), "WAVES") | |
50 | 50 | ||
51 | 51 | let w = if ((v == "WAVES")) | |
52 | 52 | then unit | |
53 | 53 | else fromBase58String(v) | |
54 | 54 | ||
55 | 55 | func x (y) = { | |
56 | 56 | let z = addressFromString(y) | |
57 | 57 | if ($isInstanceOf(z, "Address")) | |
58 | 58 | then { | |
59 | 59 | let A = z | |
60 | 60 | true | |
61 | 61 | } | |
62 | 62 | else false | |
63 | 63 | } | |
64 | 64 | ||
65 | 65 | ||
66 | 66 | func B (q,C,D) = { | |
67 | 67 | let E = makeString(["%d%d%d%d", toString(n), toString(C), toString(o), toString(D)], b) | |
68 | 68 | StringEntry(p(q), E) | |
69 | 69 | } | |
70 | 70 | ||
71 | 71 | ||
72 | 72 | func F (q) = { | |
73 | 73 | let G = getString(this, p(q)) | |
74 | 74 | let z = G | |
75 | 75 | if ($isInstanceOf(z, "String")) | |
76 | 76 | then { | |
77 | 77 | let H = z | |
78 | 78 | let I = split(H, b) | |
79 | 79 | let J = parseIntValue(I[1]) | |
80 | 80 | let K = parseIntValue(I[2]) | |
81 | 81 | let L = parseIntValue(I[3]) | |
82 | 82 | let M = parseIntValue(I[4]) | |
83 | 83 | if ((L > height)) | |
84 | 84 | then $Tuple2(K, M) | |
85 | 85 | else $Tuple2(M, M) | |
86 | 86 | } | |
87 | 87 | else $Tuple2(0, 0) | |
88 | 88 | } | |
89 | 89 | ||
90 | 90 | ||
91 | 91 | func N (q,s,O,P) = { | |
92 | 92 | let E = makeString(["%d%d%d%d", toString(n), toString(O), toString(o), toString(P)], b) | |
93 | 93 | StringEntry(t(s, q), E) | |
94 | 94 | } | |
95 | 95 | ||
96 | 96 | ||
97 | 97 | func Q (q,s) = { | |
98 | 98 | let G = getString(this, t(s, q)) | |
99 | 99 | let z = G | |
100 | 100 | if ($isInstanceOf(z, "String")) | |
101 | 101 | then { | |
102 | 102 | let H = z | |
103 | 103 | let I = split(H, b) | |
104 | 104 | let R = parseIntValue(I[1]) | |
105 | 105 | let O = parseIntValue(I[2]) | |
106 | 106 | let S = parseIntValue(I[3]) | |
107 | 107 | let P = parseIntValue(I[4]) | |
108 | 108 | if ((S > height)) | |
109 | 109 | then $Tuple2(O, P) | |
110 | 110 | else $Tuple2(P, P) | |
111 | 111 | } | |
112 | 112 | else $Tuple2(0, 0) | |
113 | 113 | } | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | func T (s,U,V) = { | |
117 | 117 | let E = makeString(["%d%d%d%d", toString(n), toString(U), toString(o), toString(V)], b) | |
118 | 118 | StringEntry(u(s), E) | |
119 | 119 | } | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func W (s) = { | |
123 | 123 | let X = getString(this, u(s)) | |
124 | 124 | let z = X | |
125 | 125 | if ($isInstanceOf(z, "String")) | |
126 | 126 | then { | |
127 | 127 | let H = z | |
128 | 128 | let I = split(H, b) | |
129 | 129 | let Y = parseIntValue(I[1]) | |
130 | 130 | let U = parseIntValue(I[2]) | |
131 | 131 | let Z = parseIntValue(I[3]) | |
132 | 132 | let V = parseIntValue(I[4]) | |
133 | 133 | if ((Z > height)) | |
134 | 134 | then $Tuple2(U, V) | |
135 | 135 | else $Tuple2((U + V), 0) | |
136 | 136 | } | |
137 | 137 | else $Tuple2(0, 0) | |
138 | 138 | } | |
139 | 139 | ||
140 | 140 | ||
141 | 141 | func aa (s) = { | |
142 | 142 | let G = getString(this, r(s)) | |
143 | 143 | let z = G | |
144 | 144 | if ($isInstanceOf(z, "String")) | |
145 | 145 | then { | |
146 | 146 | let H = z | |
147 | 147 | let I = split_51C(H, b) | |
148 | 148 | I | |
149 | 149 | } | |
150 | 150 | else nil | |
151 | 151 | } | |
152 | 152 | ||
153 | 153 | ||
154 | 154 | func ab (s,ac) = if ((size(ac) == 0)) | |
155 | 155 | then DeleteEntry(r(s)) | |
156 | 156 | else StringEntry(r(s), makeString_11C(ac, b)) | |
157 | 157 | ||
158 | 158 | ||
159 | 159 | func ad (s,q) = { | |
160 | 160 | let ac = aa(s) | |
161 | 161 | if (containsElement(ac, q)) | |
162 | 162 | then ac | |
163 | 163 | else (ac :+ q) | |
164 | 164 | } | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func ae (s,q) = { | |
168 | 168 | let ac = aa(s) | |
169 | 169 | let z = indexOf(ac, q) | |
170 | 170 | if ($isInstanceOf(z, "Int")) | |
171 | 171 | then { | |
172 | 172 | let af = z | |
173 | 173 | removeByIndex(ac, af) | |
174 | 174 | } | |
175 | 175 | else ac | |
176 | 176 | } | |
177 | 177 | ||
178 | 178 | ||
179 | 179 | func ag (q,s,ah) = { | |
180 | 180 | let ai = [if ((size(ah.payments) == 1)) | |
181 | 181 | then true | |
182 | 182 | else d("payment size should be exactly 1"), if ((ah.payments[0].assetId == w)) | |
183 | 183 | then true | |
184 | 184 | else d(makeString(["payment assetId should be:", v], " ")), if (x(q)) | |
185 | 185 | then true | |
186 | 186 | else d(makeString(["node address is not valid:", q], " ")), if (x(s)) | |
187 | 187 | then true | |
188 | 188 | else d(makeString(["user address is not valid:", s], " "))] | |
189 | 189 | if ((ai == ai)) | |
190 | 190 | then { | |
191 | 191 | let aj = ah.payments[0].amount | |
192 | 192 | let ak = F(q) | |
193 | 193 | let K = ak._1 | |
194 | 194 | let M = ak._2 | |
195 | 195 | let al = (M + aj) | |
196 | 196 | let am = Q(q, s) | |
197 | 197 | let O = am._1 | |
198 | 198 | let P = am._2 | |
199 | 199 | let an = (P + aj) | |
200 | 200 | [B(q, K, al), N(q, s, O, an), ab(s, ad(s, q))] | |
201 | 201 | } | |
202 | 202 | else throw("Strict value is not equal to itself.") | |
203 | 203 | } | |
204 | 204 | ||
205 | 205 | ||
206 | 206 | func ao (q,s,ap) = { | |
207 | 207 | let aq = F(q) | |
208 | 208 | let K = aq._1 | |
209 | 209 | let M = aq._2 | |
210 | 210 | let ar = Q(q, s) | |
211 | 211 | let O = ar._1 | |
212 | 212 | let P = ar._2 | |
213 | 213 | let ai = [if ((ap > 0)) | |
214 | 214 | then true | |
215 | 215 | else d("unstake amount should be greater than 0"), if ((P >= ap)) | |
216 | 216 | then true | |
217 | 217 | else d("unstake amount should be less or equal user staked amount"), if ((M >= ap)) | |
218 | 218 | then true | |
219 | 219 | else d("unstake amount should be less or equal node staked amount"), if (x(q)) | |
220 | 220 | then true | |
221 | 221 | else d(makeString(["node address is not valid:", q], " ")), if (x(s)) | |
222 | 222 | then true | |
223 | 223 | else d(makeString(["user address is not valid:", s], " "))] | |
224 | 224 | if ((ai == ai)) | |
225 | 225 | then { | |
226 | 226 | let al = (M - ap) | |
227 | 227 | let an = (P - ap) | |
228 | 228 | let as = W(s) | |
229 | 229 | let U = as._1 | |
230 | 230 | let V = as._2 | |
231 | 231 | let at = (V + ap) | |
232 | 232 | let au = if ((an == 0)) | |
233 | 233 | then [ab(s, ae(s, q))] | |
234 | 234 | else nil | |
235 | 235 | ([B(q, K, al), N(q, s, O, an), T(s, U, at)] ++ au) | |
236 | 236 | } | |
237 | 237 | else throw("Strict value is not equal to itself.") | |
238 | 238 | } | |
239 | 239 | ||
240 | 240 | ||
241 | 241 | func av (s,aw) = { | |
242 | 242 | let ax = W(s) | |
243 | 243 | let U = ax._1 | |
244 | 244 | let V = ax._2 | |
245 | 245 | let ai = [if ((aw > 0)) | |
246 | 246 | then true | |
247 | 247 | else d("claim amount should be greater than 0"), if ((U >= aw)) | |
248 | 248 | then true | |
249 | 249 | else d("claim amount should be less or equal unlocked amount"), if (x(s)) | |
250 | 250 | then true | |
251 | 251 | else d(makeString(["user address is not valid:", s], " "))] | |
252 | 252 | if ((ai == ai)) | |
253 | 253 | then { | |
254 | 254 | let ay = (U - aw) | |
255 | 255 | [T(s, ay, V), ScriptTransfer(addressFromStringValue(s), aw, w)] | |
256 | 256 | } | |
257 | 257 | else throw("Strict value is not equal to itself.") | |
258 | 258 | } | |
259 | 259 | ||
260 | 260 | ||
261 | 261 | func az (q,s,aj) = { | |
262 | 262 | let aA = W(s) | |
263 | 263 | let U = aA._1 | |
264 | 264 | let V = aA._2 | |
265 | 265 | let aB = (V + U) | |
266 | 266 | let ai = [if ((aj > 0)) | |
267 | 267 | then true | |
268 | 268 | else d("amount should be greater than 0"), if ((aB >= aj)) | |
269 | 269 | then true | |
270 | 270 | else d("amount should be less or equal to available"), if (x(q)) | |
271 | 271 | then true | |
272 | 272 | else d(makeString(["node address is not valid:", q], " ")), if (x(s)) | |
273 | 273 | then true | |
274 | 274 | else d(makeString(["user address is not valid:", s], " "))] | |
275 | 275 | if ((ai == ai)) | |
276 | 276 | then { | |
277 | 277 | let aC = F(q) | |
278 | 278 | let K = aC._1 | |
279 | 279 | let M = aC._2 | |
280 | 280 | let al = (M + aj) | |
281 | 281 | let aD = Q(q, s) | |
282 | 282 | let O = aD._1 | |
283 | 283 | let P = aD._2 | |
284 | 284 | let an = (P + aj) | |
285 | 285 | let at = max([0, (V - aj)]) | |
286 | 286 | let ay = min([U, (U + (V - aj))]) | |
287 | 287 | [B(q, K, M), N(q, s, O, an), T(s, ay, at), ab(s, ad(s, q))] | |
288 | 288 | } | |
289 | 289 | else throw("Strict value is not equal to itself.") | |
290 | 290 | } | |
291 | 291 | ||
292 | 292 | ||
293 | 293 | func aE (aF) = { | |
294 | 294 | let aG = [if ((aF > 0)) | |
295 | 295 | then true | |
296 | 296 | else d("period length should be greater than 0")] | |
297 | 297 | if ((aG == aG)) | |
298 | 298 | then if ((l == -1)) | |
299 | 299 | then [IntegerEntry(i, aF), IntegerEntry(h, height)] | |
300 | 300 | else { | |
301 | 301 | let aH = (m + 1) | |
302 | 302 | let aI = ((k * (aH - j)) + l) | |
303 | 303 | [IntegerEntry(g, aH), IntegerEntry(h, aI), IntegerEntry(i, aF)] | |
304 | 304 | } | |
305 | 305 | else throw("Strict value is not equal to itself.") | |
306 | 306 | } | |
307 | 307 | ||
308 | 308 | ||
309 | + | func aJ () = $Tuple3(height, n, o) | |
310 | + | ||
311 | + | ||
309 | 312 | @Callable(ah) | |
310 | 313 | func setNewPeriodLength (aF) = aE(aF) | |
311 | 314 | ||
312 | 315 | ||
313 | 316 | ||
314 | 317 | @Callable(ah) | |
315 | - | func getUserData (s) = { | |
316 | - | let aJ = W(s) | |
317 | - | let U = aJ._1 | |
318 | - | let V = aJ._2 | |
318 | + | func getNodeDataREADONLY (q) = { | |
319 | + | let aK = F(q) | |
320 | + | let aL = aK._1 | |
321 | + | let D = aK._2 | |
322 | + | let aM = aJ() | |
323 | + | let Y = aM._1 | |
324 | + | let Z = aM._2 | |
325 | + | $Tuple2(nil, $Tuple4(aL, D, Y, Z)) | |
326 | + | } | |
327 | + | ||
328 | + | ||
329 | + | ||
330 | + | @Callable(ah) | |
331 | + | func getUserDataREADONLY (s) = { | |
332 | + | let aN = W(s) | |
333 | + | let U = aN._1 | |
334 | + | let V = aN._2 | |
319 | 335 | let ac = aa(s) | |
320 | - | $Tuple2(nil, $ | |
336 | + | $Tuple2(nil, $Tuple4(U, V, aJ(), ac)) | |
321 | 337 | } | |
322 | 338 | ||
323 | 339 | ||
324 | 340 | ||
325 | 341 | @Callable(ah) | |
326 | 342 | func stakeFor (q,s) = ag(q, s, ah) | |
327 | 343 | ||
328 | 344 | ||
329 | 345 | ||
330 | 346 | @Callable(ah) | |
331 | 347 | func stake (q) = { | |
332 | 348 | let s = toString(ah.caller) | |
333 | 349 | ag(q, s, ah) | |
334 | 350 | } | |
335 | 351 | ||
336 | 352 | ||
337 | 353 | ||
338 | 354 | @Callable(ah) | |
339 | - | func stakeFromUnlocked (q, | |
355 | + | func stakeFromUnlocked (q,aO) = { | |
340 | 356 | let s = toString(ah.caller) | |
341 | - | az(q, s, | |
357 | + | az(q, s, aO) | |
342 | 358 | } | |
343 | 359 | ||
344 | 360 | ||
345 | 361 | ||
346 | 362 | @Callable(ah) | |
347 | - | func unstake (q, | |
363 | + | func unstake (q,aO) = { | |
348 | 364 | let s = toString(ah.caller) | |
349 | - | ao(q, s, | |
365 | + | ao(q, s, aO) | |
350 | 366 | } | |
351 | 367 | ||
352 | 368 | ||
353 | 369 | ||
354 | 370 | @Callable(ah) | |
355 | - | func claim ( | |
371 | + | func claim (aO) = { | |
356 | 372 | let s = toString(ah.caller) | |
357 | - | av(s, | |
373 | + | av(s, aO) | |
358 | 374 | } | |
359 | 375 | ||
360 | 376 | ||
361 | 377 | ||
362 | 378 | @Callable(ah) | |
363 | 379 | func claimAll () = { | |
364 | 380 | let s = toString(ah.caller) | |
365 | - | let | |
366 | - | let U = | |
367 | - | let V = | |
381 | + | let aP = W(s) | |
382 | + | let U = aP._1 | |
383 | + | let V = aP._2 | |
368 | 384 | av(s, U) | |
369 | 385 | } | |
370 | 386 | ||
371 | 387 |
github/deemru/w8io/169f3d6 41.76 ms ◑