tx · 7U2gXgagFegASqNPizi59LYpDD6nuBivpJagzczA9eKZ 3MzJZEn6jzxCPaHEfkrXd7FhbjTyVjdRPLS: -0.01400000 Waves 2021.04.15 17:00 [1483651] smart account 3MzJZEn6jzxCPaHEfkrXd7FhbjTyVjdRPLS > SELF 0.00000000 Waves
{ "type": 13, "id": "7U2gXgagFegASqNPizi59LYpDD6nuBivpJagzczA9eKZ", "fee": 1400000, "feeAssetId": null, "timestamp": 1618495284115, "version": 2, "chainId": 84, "sender": "3MzJZEn6jzxCPaHEfkrXd7FhbjTyVjdRPLS", "senderPublicKey": "93SZf1TATCRxGyBuGyngpQGKcpKZirb2yXLT2RQJ3UKb", "proofs": [ "42qrPxZXLSvMG9cJzgwM6ge3tw5QZpuBDQigKSYkPVNdVpDaQTMs9zQt6BLKdwiVg8cJFoM5Fx5Tdrm3YeNem2Uv" ], "script": "base64:AAIEAAAAAAAAABwIAhIAEgASAwoBARIAEgASBwoFGBEYEQESABIAAAAAOQAAAAAMYWRtaW5QdWJLZXkxAQAAACAEz3XlZNDBD05nuR8TZMQaDeqEJEIxfTOQXUBYCp2TSgAAAAAMYWRtaW5QdWJLZXkyAQAAACAEz3XlZNDBD05nuR8TZMQaDeqEJEIxfTOQXUBYCp2TSgAAAAAMYWRtaW5QdWJLZXkzAQAAACAEz3XlZNDBD05nuR8TZMQaDeqEJEIxfTOQXUBYCp2TSgAAAAAUYWRtaW5QdWJLZXlTdGFydFN0b3ABAAAAIATPdeVk0MEPTme5HxNkxBoN6oQkQjF9M5BdQFgKnZNKAAAAABFhZG1pblB1YktleVdhbGxldAEAAAAgPndaZVpWyfwpVzO1vA1FLcrMp/iFkg43d1jzYhVSFBIAAAAACWtleUFjdGl2ZQIAAAAGYWN0aXZlAAAAAAhrZXlDYXVzZQIAAAAOc2h1dGRvd25fY2F1c2UAAAAAD2tleUxhc3RJbnRlcmVzdAIAAAANbGFzdF9pbnRlcmVzdAAAAAATa2V5VXNlckxhc3RJbnRlcmVzdAIAAA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2V5MQkABEwAAAACBQAAAAxhZG1pblB1YktleTIJAARMAAAAAgUAAAAMYWRtaW5QdWJLZXkzCQAETAAAAAIFAAAAFGFkbWluUHViS2V5U3RhcnRTdG9wBQAAAANuaWwIBQAAAAFpAAAAD2NhbGxlclB1YmxpY0tleQkAAAIAAAABAgAAACFPbmx5IGFkbWluIGNhbiBjYWxsIHRoaXMgZnVuY3Rpb24JAARMAAAAAgkBAAAADEJvb2xlYW5FbnRyeQAAAAIFAAAACWtleUFjdGl2ZQYJAARMAAAAAgkBAAAAC0RlbGV0ZUVudHJ5AAAAAQUAAAAIa2V5Q2F1c2UFAAAAA25pbAAAAAEAAAACdHgBAAAABnZlcmlmeQAAAAAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5Jl+22Q==", "height": 1483651, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9CQyf3xv6RnTxPJ5exCHYWxWvChgf3c6XCqm2bbYtLMs Next: C5Vft2V9JP7JvXkxvzSPVgpPTmmCQkhNXfpbnq5KfdTE Diff:
Old | New | Differences | |
---|---|---|---|
67 | 67 | ||
68 | 68 | let totalVoteShare = 10000000000 | |
69 | 69 | ||
70 | + | let kStartHeight = "start_height" | |
71 | + | ||
72 | + | let kBasePeriod = "base_period" | |
73 | + | ||
74 | + | let kPeriodLength = "period_length" | |
75 | + | ||
76 | + | let kUserTotalStruc = "_user_total_struc" | |
77 | + | ||
78 | + | let basePeriod = valueOrErrorMessage(getInteger(votingLiteContract, kBasePeriod), "Empty kBasePeriod at voting contract") | |
79 | + | ||
80 | + | let startHeight = valueOrErrorMessage(getInteger(votingLiteContract, kStartHeight), "Empty kStartHeight at voting contract") | |
81 | + | ||
82 | + | let periodLength = valueOrErrorMessage(getInteger(votingLiteContract, kPeriodLength), "Empty kPeriodLength at voting contract") | |
83 | + | ||
84 | + | let currVotingPeriod = (basePeriod + ((height - startHeight) / periodLength)) | |
85 | + | ||
70 | 86 | func suspend (cause) = [BooleanEntry(keyActive, false), StringEntry(keyCause, cause)] | |
71 | 87 | ||
72 | 88 | ||
101 | 117 | func getTotalSWOPLocked () = valueOrElse(getInteger(this, keyTotalSWOPLocked), 0) | |
102 | 118 | ||
103 | 119 | ||
104 | - | func getUserTotalVoteAmount (user) = valueOrElse(getInteger(votingLiteContract, (toString(user) + kUserTotalVoteSWOP)), 0) | |
120 | + | func getUserUnvoteAmount (user) = { | |
121 | + | let $t037844323 = if (isDefined(getString(this, (toString(user) + kUserTotalStruc)))) | |
122 | + | then { | |
123 | + | let data = split(valueOrErrorMessage(getString(votingLiteContract, (toString(user) + kUserTotalStruc)), "Empty kUserTotalStruc"), "_") | |
124 | + | $Tuple3(parseIntValue(data[0]), parseIntValue(data[1]), parseIntValue(data[2])) | |
125 | + | } | |
126 | + | else { | |
127 | + | let uPoolTotalSWOP = valueOrElse(getInteger(votingLiteContract, (toString(user) + kUserTotalVoteSWOP)), 0) | |
128 | + | $Tuple3(uPoolTotalSWOP, 0, currVotingPeriod) | |
129 | + | } | |
130 | + | let userTotalVoteSWOP = $t037844323._1 | |
131 | + | let userUnvoted = $t037844323._2 | |
132 | + | let userUnvotedPeriod = $t037844323._3 | |
133 | + | if ((userUnvotedPeriod == currVotingPeriod)) | |
134 | + | then userUnvoted | |
135 | + | else 0 | |
136 | + | } | |
105 | 137 | ||
106 | 138 | ||
107 | 139 | func getUserVoteOptionAmount (user) = valueOrElse(getInteger(this, (toString(user) + keyUserVoteOptionAmount)), 0) | |
141 | 173 | } | |
142 | 174 | ||
143 | 175 | ||
176 | + | func getUserTotalVoteAmount (user) = { | |
177 | + | let $t057096220 = if (isDefined(getString(this, (toString(user) + kUserTotalStruc)))) | |
178 | + | then { | |
179 | + | let data = split(valueOrErrorMessage(getString(this, (toString(user) + kUserTotalStruc)), "Empty kUserTotalStruc"), "_") | |
180 | + | $Tuple3(parseIntValue(data[0]), parseIntValue(data[1]), parseIntValue(data[2])) | |
181 | + | } | |
182 | + | else { | |
183 | + | let uPoolTotalSWOP = valueOrElse(getInteger(this, (toString(user) + kUserTotalVoteSWOP)), 0) | |
184 | + | $Tuple3(uPoolTotalSWOP, 0, currVotingPeriod) | |
185 | + | } | |
186 | + | let userTotalVoteSWOP = $t057096220._1 | |
187 | + | let userUnvoted = $t057096220._2 | |
188 | + | let userUnvotedPeriod = $t057096220._3 | |
189 | + | userTotalVoteSWOP | |
190 | + | } | |
191 | + | ||
192 | + | ||
144 | 193 | func getUserGetBackAmount (voteName,option,user,getBackSWOPHeight) = { | |
145 | 194 | let key = ((((((voteName + "_") + option) + "_") + toString(user)) + "_") + toString(getBackSWOPHeight)) | |
146 | 195 | valueOrErrorMessage(getInteger(this, key), ("No data on the key: " + key)) | |
149 | 198 | ||
150 | 199 | func claimCalc (caller) = { | |
151 | 200 | let lastInterest = getLastInterestInfo() | |
152 | - | let $ | |
153 | - | let userLastInterest = $ | |
154 | - | let userSWOPLocked = $ | |
201 | + | let $t066556735 = getUserInterestInfo(caller, lastInterest) | |
202 | + | let userLastInterest = $t066556735._1 | |
203 | + | let userSWOPLocked = $t066556735._2 | |
155 | 204 | let claimAmount = fraction(userSWOPLocked, (lastInterest - userLastInterest), scaleValue) | |
156 | 205 | let userNewInterest = lastInterest | |
157 | 206 | $Tuple2(userNewInterest, claimAmount) | |
162 | 211 | func airDrop () = if (!(isActive)) | |
163 | 212 | then throw("DApp is inactive at this moment") | |
164 | 213 | else { | |
165 | - | let $ | |
166 | - | let pmtAmount = $ | |
167 | - | let pmtAssetId = $ | |
214 | + | let $t070007075 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
215 | + | let pmtAmount = $t070007075._1 | |
216 | + | let pmtAssetId = $t070007075._2 | |
168 | 217 | if ((pmtAssetId != SWOP)) | |
169 | 218 | then throw("Incorrect pmtAssetId") | |
170 | 219 | else { | |
181 | 230 | func lockSWOP () = if (!(isActive)) | |
182 | 231 | then throw("DApp is inactive at this moment") | |
183 | 232 | else { | |
184 | - | let $ | |
185 | - | let pmtAmount = $ | |
186 | - | let pmtAssetId = $ | |
233 | + | let $t075137588 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
234 | + | let pmtAmount = $t075137588._1 | |
235 | + | let pmtAssetId = $t075137588._2 | |
187 | 236 | if ((pmtAssetId != SWOP)) | |
188 | 237 | then throw("Incorrect pmtAssetId") | |
189 | 238 | else { | |
190 | 239 | let lastInterest = getLastInterestInfo() | |
191 | - | let $ | |
192 | - | let userLastInterest = $ | |
193 | - | let userSWOPLocked = $ | |
240 | + | let $t077047786 = getUserInterestInfo(i.caller, lastInterest) | |
241 | + | let userLastInterest = $t077047786._1 | |
242 | + | let userSWOPLocked = $t077047786._2 | |
194 | 243 | let claimAmount = fraction(userSWOPLocked, (lastInterest - userLastInterest), scaleValue) | |
195 | 244 | let userSWOPLockedNew = ((userSWOPLocked + pmtAmount) + claimAmount) | |
196 | 245 | let userNewInterest = lastInterest | |
210 | 259 | else { | |
211 | 260 | let totalSWOPLocked = getTotalSWOPLocked() | |
212 | 261 | let userSWOPLocked = getUserSWOPLocked(i.caller) | |
213 | - | let $ | |
214 | - | let userNewInterest = $ | |
215 | - | let claimAmount = $ | |
262 | + | let $t088708925 = claimCalc(i.caller) | |
263 | + | let userNewInterest = $t088708925._1 | |
264 | + | let claimAmount = $t088708925._2 | |
216 | 265 | let userVoteAmount = getUserTotalVoteAmount(i.caller) | |
217 | - | let availableFund = (userSWOPLocked - userVoteAmount) | |
218 | - | if ((withdrawAmount > availableFund)) | |
219 | - | then throw("withdrawAmount > availableFund") | |
266 | + | let userUnvoteAmount = getUserUnvoteAmount(i.caller) | |
267 | + | if (if ((0 > userUnvoteAmount)) | |
268 | + | then true | |
269 | + | else (0 > userVoteAmount)) | |
270 | + | then throw("userUnvoteAmount < 0 || userVoteAmount < 0") | |
220 | 271 | else { | |
221 | - | let totalSWOPLockedNew = ((totalSWOPLocked + claimAmount) - withdrawAmount) | |
222 | - | let userSWOPamountNew = ((userSWOPLocked + claimAmount) - withdrawAmount) | |
223 | - | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
224 | - | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
272 | + | let availableToUnstake = ((userSWOPLocked - userVoteAmount) - userUnvoteAmount) | |
273 | + | if ((withdrawAmount > availableToUnstake)) | |
274 | + | then throw("withdrawAmount > availableToUnstake") | |
275 | + | else { | |
276 | + | let totalSWOPLockedNew = ((totalSWOPLocked + claimAmount) - withdrawAmount) | |
277 | + | let userSWOPamountNew = ((userSWOPLocked + claimAmount) - withdrawAmount) | |
278 | + | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
279 | + | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
225 | 280 | [IntegerEntry((toString(i.caller) + keyUserLastInterest), userNewInterest), IntegerEntry((toString(i.caller) + keyUserSWOPLocked), userSWOPamountNew), IntegerEntry(keyTotalSWOPLocked, totalSWOPLockedNew), ScriptTransfer(i.caller, withdrawAmount, SWOP), IntegerEntry((toString(i.caller) + keyUserSWOPClaimedAmount), userClaimedAmountNew), IntegerEntry((toString(i.caller) + keyUserSWOPLastClaimedAmount), claimAmount)] | |
281 | + | } | |
226 | 282 | } | |
227 | 283 | } | |
228 | 284 | ||
233 | 289 | then throw("DApp is inactive at this moment") | |
234 | 290 | else { | |
235 | 291 | let lastInterest = getLastInterestInfo() | |
236 | - | let $ | |
237 | - | let userNewInterest = $ | |
238 | - | let claimAmount = $ | |
292 | + | let $t01024110296 = claimCalc(i.caller) | |
293 | + | let userNewInterest = $t01024110296._1 | |
294 | + | let claimAmount = $t01024110296._2 | |
239 | 295 | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
240 | 296 | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
241 | 297 | if ((claimAmount == 0)) | |
252 | 308 | let totalSWOPLocked = getTotalSWOPLocked() | |
253 | 309 | let userSWOPLocked = getUserSWOPLocked(i.caller) | |
254 | 310 | let lastInterest = getLastInterestInfo() | |
255 | - | let $ | |
256 | - | let userNewInterest = $ | |
257 | - | let claimAmount = $ | |
311 | + | let $t01107511130 = claimCalc(i.caller) | |
312 | + | let userNewInterest = $t01107511130._1 | |
313 | + | let claimAmount = $t01107511130._2 | |
258 | 314 | let userSWOPLockedNew = (userSWOPLocked + claimAmount) | |
259 | 315 | let totalSWOPLockedNew = (totalSWOPLocked + claimAmount) | |
260 | 316 | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
269 | 325 | @Callable(i) | |
270 | 326 | func updateWeights (previousPools,previousRewards,currentPools,currentRewards,rewardUpdateHeight) = if (!(isActive)) | |
271 | 327 | then throw("DApp is inactive at this moment") | |
272 | - | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop | |
328 | + | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop], i.callerPublicKey))) | |
273 | 329 | then throw("Only admin can call this function") | |
274 | 330 | else { | |
275 | 331 | func sum (a,b) = (a + b) | |
287 | 343 | } | |
288 | 344 | ||
289 | 345 | let sumRewardPrevious = { | |
290 | - | let $ | |
291 | - | let $ | |
292 | - | let $ | |
293 | - | if (($ | |
294 | - | then $ | |
346 | + | let $list1289712930 = previousRewards | |
347 | + | let $size1289712930 = size($list1289712930) | |
348 | + | let $acc01289712930 = 0 | |
349 | + | if (($size1289712930 == 0)) | |
350 | + | then $acc01289712930 | |
295 | 351 | else { | |
296 | - | let $ | |
297 | - | if (($ | |
298 | - | then $ | |
352 | + | let $acc11289712930 = sum($acc01289712930, $list1289712930[0]) | |
353 | + | if (($size1289712930 == 1)) | |
354 | + | then $acc11289712930 | |
299 | 355 | else { | |
300 | - | let $ | |
301 | - | if (($ | |
302 | - | then $ | |
356 | + | let $acc21289712930 = sum($acc11289712930, $list1289712930[1]) | |
357 | + | if (($size1289712930 == 2)) | |
358 | + | then $acc21289712930 | |
303 | 359 | else { | |
304 | - | let $ | |
305 | - | if (($ | |
306 | - | then $ | |
360 | + | let $acc31289712930 = sum($acc21289712930, $list1289712930[2]) | |
361 | + | if (($size1289712930 == 3)) | |
362 | + | then $acc31289712930 | |
307 | 363 | else { | |
308 | - | let $ | |
309 | - | if (($ | |
310 | - | then $ | |
364 | + | let $acc41289712930 = sum($acc31289712930, $list1289712930[3]) | |
365 | + | if (($size1289712930 == 4)) | |
366 | + | then $acc41289712930 | |
311 | 367 | else { | |
312 | - | let $ | |
313 | - | if (($ | |
314 | - | then $ | |
368 | + | let $acc51289712930 = sum($acc41289712930, $list1289712930[4]) | |
369 | + | if (($size1289712930 == 5)) | |
370 | + | then $acc51289712930 | |
315 | 371 | else { | |
316 | - | let $ | |
317 | - | if (($ | |
318 | - | then $ | |
372 | + | let $acc61289712930 = sum($acc51289712930, $list1289712930[5]) | |
373 | + | if (($size1289712930 == 6)) | |
374 | + | then $acc61289712930 | |
319 | 375 | else { | |
320 | - | let $ | |
321 | - | if (($ | |
322 | - | then $ | |
376 | + | let $acc71289712930 = sum($acc61289712930, $list1289712930[6]) | |
377 | + | if (($size1289712930 == 7)) | |
378 | + | then $acc71289712930 | |
323 | 379 | else { | |
324 | - | let $ | |
325 | - | if (($ | |
326 | - | then $ | |
380 | + | let $acc81289712930 = sum($acc71289712930, $list1289712930[7]) | |
381 | + | if (($size1289712930 == 8)) | |
382 | + | then $acc81289712930 | |
327 | 383 | else { | |
328 | - | let $ | |
329 | - | if (($ | |
330 | - | then $ | |
384 | + | let $acc91289712930 = sum($acc81289712930, $list1289712930[8]) | |
385 | + | if (($size1289712930 == 9)) | |
386 | + | then $acc91289712930 | |
331 | 387 | else { | |
332 | - | let $ | |
333 | - | if (($ | |
334 | - | then $ | |
388 | + | let $acc101289712930 = sum($acc91289712930, $list1289712930[9]) | |
389 | + | if (($size1289712930 == 10)) | |
390 | + | then $acc101289712930 | |
335 | 391 | else { | |
336 | - | let $ | |
337 | - | if (($ | |
338 | - | then $ | |
392 | + | let $acc111289712930 = sum($acc101289712930, $list1289712930[10]) | |
393 | + | if (($size1289712930 == 11)) | |
394 | + | then $acc111289712930 | |
339 | 395 | else { | |
340 | - | let $ | |
341 | - | if (($ | |
342 | - | then $ | |
396 | + | let $acc121289712930 = sum($acc111289712930, $list1289712930[11]) | |
397 | + | if (($size1289712930 == 12)) | |
398 | + | then $acc121289712930 | |
343 | 399 | else { | |
344 | - | let $ | |
345 | - | if (($ | |
346 | - | then $ | |
400 | + | let $acc131289712930 = sum($acc121289712930, $list1289712930[12]) | |
401 | + | if (($size1289712930 == 13)) | |
402 | + | then $acc131289712930 | |
347 | 403 | else { | |
348 | - | let $ | |
349 | - | if (($ | |
350 | - | then $ | |
404 | + | let $acc141289712930 = sum($acc131289712930, $list1289712930[13]) | |
405 | + | if (($size1289712930 == 14)) | |
406 | + | then $acc141289712930 | |
351 | 407 | else { | |
352 | - | let $ | |
353 | - | if (($ | |
354 | - | then $ | |
408 | + | let $acc151289712930 = sum($acc141289712930, $list1289712930[14]) | |
409 | + | if (($size1289712930 == 15)) | |
410 | + | then $acc151289712930 | |
355 | 411 | else { | |
356 | - | let $ | |
357 | - | if (($ | |
358 | - | then $ | |
412 | + | let $acc161289712930 = sum($acc151289712930, $list1289712930[15]) | |
413 | + | if (($size1289712930 == 16)) | |
414 | + | then $acc161289712930 | |
359 | 415 | else { | |
360 | - | let $ | |
361 | - | if (($ | |
362 | - | then $ | |
416 | + | let $acc171289712930 = sum($acc161289712930, $list1289712930[16]) | |
417 | + | if (($size1289712930 == 17)) | |
418 | + | then $acc171289712930 | |
363 | 419 | else { | |
364 | - | let $ | |
365 | - | if (($ | |
366 | - | then $ | |
420 | + | let $acc181289712930 = sum($acc171289712930, $list1289712930[17]) | |
421 | + | if (($size1289712930 == 18)) | |
422 | + | then $acc181289712930 | |
367 | 423 | else { | |
368 | - | let $ | |
369 | - | if (($ | |
370 | - | then $ | |
424 | + | let $acc191289712930 = sum($acc181289712930, $list1289712930[18]) | |
425 | + | if (($size1289712930 == 19)) | |
426 | + | then $acc191289712930 | |
371 | 427 | else { | |
372 | - | let $ | |
373 | - | if (($ | |
374 | - | then $ | |
428 | + | let $acc201289712930 = sum($acc191289712930, $list1289712930[19]) | |
429 | + | if (($size1289712930 == 20)) | |
430 | + | then $acc201289712930 | |
375 | 431 | else { | |
376 | - | let $ | |
432 | + | let $acc211289712930 = sum($acc201289712930, $list1289712930[20]) | |
377 | 433 | throw("List size exceed 20") | |
378 | 434 | } | |
379 | 435 | } | |
398 | 454 | } | |
399 | 455 | } | |
400 | 456 | let sumRewardCurrent = { | |
401 | - | let $ | |
402 | - | let $ | |
403 | - | let $ | |
404 | - | if (($ | |
405 | - | then $ | |
457 | + | let $list1295912991 = currentRewards | |
458 | + | let $size1295912991 = size($list1295912991) | |
459 | + | let $acc01295912991 = 0 | |
460 | + | if (($size1295912991 == 0)) | |
461 | + | then $acc01295912991 | |
406 | 462 | else { | |
407 | - | let $ | |
408 | - | if (($ | |
409 | - | then $ | |
463 | + | let $acc11295912991 = sum($acc01295912991, $list1295912991[0]) | |
464 | + | if (($size1295912991 == 1)) | |
465 | + | then $acc11295912991 | |
410 | 466 | else { | |
411 | - | let $ | |
412 | - | if (($ | |
413 | - | then $ | |
467 | + | let $acc21295912991 = sum($acc11295912991, $list1295912991[1]) | |
468 | + | if (($size1295912991 == 2)) | |
469 | + | then $acc21295912991 | |
414 | 470 | else { | |
415 | - | let $ | |
416 | - | if (($ | |
417 | - | then $ | |
471 | + | let $acc31295912991 = sum($acc21295912991, $list1295912991[2]) | |
472 | + | if (($size1295912991 == 3)) | |
473 | + | then $acc31295912991 | |
418 | 474 | else { | |
419 | - | let $ | |
420 | - | if (($ | |
421 | - | then $ | |
475 | + | let $acc41295912991 = sum($acc31295912991, $list1295912991[3]) | |
476 | + | if (($size1295912991 == 4)) | |
477 | + | then $acc41295912991 | |
422 | 478 | else { | |
423 | - | let $ | |
424 | - | if (($ | |
425 | - | then $ | |
479 | + | let $acc51295912991 = sum($acc41295912991, $list1295912991[4]) | |
480 | + | if (($size1295912991 == 5)) | |
481 | + | then $acc51295912991 | |
426 | 482 | else { | |
427 | - | let $ | |
428 | - | if (($ | |
429 | - | then $ | |
483 | + | let $acc61295912991 = sum($acc51295912991, $list1295912991[5]) | |
484 | + | if (($size1295912991 == 6)) | |
485 | + | then $acc61295912991 | |
430 | 486 | else { | |
431 | - | let $ | |
432 | - | if (($ | |
433 | - | then $ | |
487 | + | let $acc71295912991 = sum($acc61295912991, $list1295912991[6]) | |
488 | + | if (($size1295912991 == 7)) | |
489 | + | then $acc71295912991 | |
434 | 490 | else { | |
435 | - | let $ | |
436 | - | if (($ | |
437 | - | then $ | |
491 | + | let $acc81295912991 = sum($acc71295912991, $list1295912991[7]) | |
492 | + | if (($size1295912991 == 8)) | |
493 | + | then $acc81295912991 | |
438 | 494 | else { | |
439 | - | let $ | |
440 | - | if (($ | |
441 | - | then $ | |
495 | + | let $acc91295912991 = sum($acc81295912991, $list1295912991[8]) | |
496 | + | if (($size1295912991 == 9)) | |
497 | + | then $acc91295912991 | |
442 | 498 | else { | |
443 | - | let $ | |
444 | - | if (($ | |
445 | - | then $ | |
499 | + | let $acc101295912991 = sum($acc91295912991, $list1295912991[9]) | |
500 | + | if (($size1295912991 == 10)) | |
501 | + | then $acc101295912991 | |
446 | 502 | else { | |
447 | - | let $ | |
448 | - | if (($ | |
449 | - | then $ | |
503 | + | let $acc111295912991 = sum($acc101295912991, $list1295912991[10]) | |
504 | + | if (($size1295912991 == 11)) | |
505 | + | then $acc111295912991 | |
450 | 506 | else { | |
451 | - | let $ | |
452 | - | if (($ | |
453 | - | then $ | |
507 | + | let $acc121295912991 = sum($acc111295912991, $list1295912991[11]) | |
508 | + | if (($size1295912991 == 12)) | |
509 | + | then $acc121295912991 | |
454 | 510 | else { | |
455 | - | let $ | |
456 | - | if (($ | |
457 | - | then $ | |
511 | + | let $acc131295912991 = sum($acc121295912991, $list1295912991[12]) | |
512 | + | if (($size1295912991 == 13)) | |
513 | + | then $acc131295912991 | |
458 | 514 | else { | |
459 | - | let $ | |
460 | - | if (($ | |
461 | - | then $ | |
515 | + | let $acc141295912991 = sum($acc131295912991, $list1295912991[13]) | |
516 | + | if (($size1295912991 == 14)) | |
517 | + | then $acc141295912991 | |
462 | 518 | else { | |
463 | - | let $ | |
464 | - | if (($ | |
465 | - | then $ | |
519 | + | let $acc151295912991 = sum($acc141295912991, $list1295912991[14]) | |
520 | + | if (($size1295912991 == 15)) | |
521 | + | then $acc151295912991 | |
466 | 522 | else { | |
467 | - | let $ | |
468 | - | if (($ | |
469 | - | then $ | |
523 | + | let $acc161295912991 = sum($acc151295912991, $list1295912991[15]) | |
524 | + | if (($size1295912991 == 16)) | |
525 | + | then $acc161295912991 | |
470 | 526 | else { | |
471 | - | let $ | |
472 | - | if (($ | |
473 | - | then $ | |
527 | + | let $acc171295912991 = sum($acc161295912991, $list1295912991[16]) | |
528 | + | if (($size1295912991 == 17)) | |
529 | + | then $acc171295912991 | |
474 | 530 | else { | |
475 | - | let $ | |
476 | - | if (($ | |
477 | - | then $ | |
531 | + | let $acc181295912991 = sum($acc171295912991, $list1295912991[17]) | |
532 | + | if (($size1295912991 == 18)) | |
533 | + | then $acc181295912991 | |
478 | 534 | else { | |
479 | - | let $ | |
480 | - | if (($ | |
481 | - | then $ | |
535 | + | let $acc191295912991 = sum($acc181295912991, $list1295912991[18]) | |
536 | + | if (($size1295912991 == 19)) | |
537 | + | then $acc191295912991 | |
482 | 538 | else { | |
483 | - | let $ | |
484 | - | if (($ | |
485 | - | then $ | |
539 | + | let $acc201295912991 = sum($acc191295912991, $list1295912991[19]) | |
540 | + | if (($size1295912991 == 20)) | |
541 | + | then $acc201295912991 | |
486 | 542 | else { | |
487 | - | let $ | |
543 | + | let $acc211295912991 = sum($acc201295912991, $list1295912991[20]) | |
488 | 544 | throw("List size exceed 20") | |
489 | 545 | } | |
490 | 546 | } | |
516 | 572 | then throw("sumRewardPrevious != totalVoteShare or sumRewardCurrent != totalVoteShare") | |
517 | 573 | else { | |
518 | 574 | let previousRewardEntryNew = { | |
519 | - | let $ | |
520 | - | let $ | |
521 | - | let $ | |
522 | - | if (($ | |
523 | - | then $ | |
575 | + | let $list1330313351 = previousPools | |
576 | + | let $size1330313351 = size($list1330313351) | |
577 | + | let $acc01330313351 = nil | |
578 | + | if (($size1330313351 == 0)) | |
579 | + | then $acc01330313351 | |
524 | 580 | else { | |
525 | - | let $ | |
526 | - | if (($ | |
527 | - | then $ | |
581 | + | let $acc11330313351 = PreviousRewardEntry($acc01330313351, $list1330313351[0]) | |
582 | + | if (($size1330313351 == 1)) | |
583 | + | then $acc11330313351 | |
528 | 584 | else { | |
529 | - | let $ | |
530 | - | if (($ | |
531 | - | then $ | |
585 | + | let $acc21330313351 = PreviousRewardEntry($acc11330313351, $list1330313351[1]) | |
586 | + | if (($size1330313351 == 2)) | |
587 | + | then $acc21330313351 | |
532 | 588 | else { | |
533 | - | let $ | |
534 | - | if (($ | |
535 | - | then $ | |
589 | + | let $acc31330313351 = PreviousRewardEntry($acc21330313351, $list1330313351[2]) | |
590 | + | if (($size1330313351 == 3)) | |
591 | + | then $acc31330313351 | |
536 | 592 | else { | |
537 | - | let $ | |
538 | - | if (($ | |
539 | - | then $ | |
593 | + | let $acc41330313351 = PreviousRewardEntry($acc31330313351, $list1330313351[3]) | |
594 | + | if (($size1330313351 == 4)) | |
595 | + | then $acc41330313351 | |
540 | 596 | else { | |
541 | - | let $ | |
542 | - | if (($ | |
543 | - | then $ | |
597 | + | let $acc51330313351 = PreviousRewardEntry($acc41330313351, $list1330313351[4]) | |
598 | + | if (($size1330313351 == 5)) | |
599 | + | then $acc51330313351 | |
544 | 600 | else { | |
545 | - | let $ | |
546 | - | if (($ | |
547 | - | then $ | |
601 | + | let $acc61330313351 = PreviousRewardEntry($acc51330313351, $list1330313351[5]) | |
602 | + | if (($size1330313351 == 6)) | |
603 | + | then $acc61330313351 | |
548 | 604 | else { | |
549 | - | let $ | |
550 | - | if (($ | |
551 | - | then $ | |
605 | + | let $acc71330313351 = PreviousRewardEntry($acc61330313351, $list1330313351[6]) | |
606 | + | if (($size1330313351 == 7)) | |
607 | + | then $acc71330313351 | |
552 | 608 | else { | |
553 | - | let $ | |
554 | - | if (($ | |
555 | - | then $ | |
609 | + | let $acc81330313351 = PreviousRewardEntry($acc71330313351, $list1330313351[7]) | |
610 | + | if (($size1330313351 == 8)) | |
611 | + | then $acc81330313351 | |
556 | 612 | else { | |
557 | - | let $ | |
558 | - | if (($ | |
559 | - | then $ | |
613 | + | let $acc91330313351 = PreviousRewardEntry($acc81330313351, $list1330313351[8]) | |
614 | + | if (($size1330313351 == 9)) | |
615 | + | then $acc91330313351 | |
560 | 616 | else { | |
561 | - | let $ | |
562 | - | if (($ | |
563 | - | then $ | |
617 | + | let $acc101330313351 = PreviousRewardEntry($acc91330313351, $list1330313351[9]) | |
618 | + | if (($size1330313351 == 10)) | |
619 | + | then $acc101330313351 | |
564 | 620 | else { | |
565 | - | let $ | |
566 | - | if (($ | |
567 | - | then $ | |
621 | + | let $acc111330313351 = PreviousRewardEntry($acc101330313351, $list1330313351[10]) | |
622 | + | if (($size1330313351 == 11)) | |
623 | + | then $acc111330313351 | |
568 | 624 | else { | |
569 | - | let $ | |
570 | - | if (($ | |
571 | - | then $ | |
625 | + | let $acc121330313351 = PreviousRewardEntry($acc111330313351, $list1330313351[11]) | |
626 | + | if (($size1330313351 == 12)) | |
627 | + | then $acc121330313351 | |
572 | 628 | else { | |
573 | - | let $ | |
574 | - | if (($ | |
575 | - | then $ | |
629 | + | let $acc131330313351 = PreviousRewardEntry($acc121330313351, $list1330313351[12]) | |
630 | + | if (($size1330313351 == 13)) | |
631 | + | then $acc131330313351 | |
576 | 632 | else { | |
577 | - | let $ | |
578 | - | if (($ | |
579 | - | then $ | |
633 | + | let $acc141330313351 = PreviousRewardEntry($acc131330313351, $list1330313351[13]) | |
634 | + | if (($size1330313351 == 14)) | |
635 | + | then $acc141330313351 | |
580 | 636 | else { | |
581 | - | let $ | |
582 | - | if (($ | |
583 | - | then $ | |
637 | + | let $acc151330313351 = PreviousRewardEntry($acc141330313351, $list1330313351[14]) | |
638 | + | if (($size1330313351 == 15)) | |
639 | + | then $acc151330313351 | |
584 | 640 | else { | |
585 | - | let $ | |
586 | - | if (($ | |
587 | - | then $ | |
641 | + | let $acc161330313351 = PreviousRewardEntry($acc151330313351, $list1330313351[15]) | |
642 | + | if (($size1330313351 == 16)) | |
643 | + | then $acc161330313351 | |
588 | 644 | else { | |
589 | - | let $ | |
590 | - | if (($ | |
591 | - | then $ | |
645 | + | let $acc171330313351 = PreviousRewardEntry($acc161330313351, $list1330313351[16]) | |
646 | + | if (($size1330313351 == 17)) | |
647 | + | then $acc171330313351 | |
592 | 648 | else { | |
593 | - | let $ | |
594 | - | if (($ | |
595 | - | then $ | |
649 | + | let $acc181330313351 = PreviousRewardEntry($acc171330313351, $list1330313351[17]) | |
650 | + | if (($size1330313351 == 18)) | |
651 | + | then $acc181330313351 | |
596 | 652 | else { | |
597 | - | let $ | |
598 | - | if (($ | |
599 | - | then $ | |
653 | + | let $acc191330313351 = PreviousRewardEntry($acc181330313351, $list1330313351[18]) | |
654 | + | if (($size1330313351 == 19)) | |
655 | + | then $acc191330313351 | |
600 | 656 | else { | |
601 | - | let $ | |
602 | - | if (($ | |
603 | - | then $ | |
657 | + | let $acc201330313351 = PreviousRewardEntry($acc191330313351, $list1330313351[19]) | |
658 | + | if (($size1330313351 == 20)) | |
659 | + | then $acc201330313351 | |
604 | 660 | else { | |
605 | - | let $ | |
661 | + | let $acc211330313351 = PreviousRewardEntry($acc201330313351, $list1330313351[20]) | |
606 | 662 | throw("List size exceed 20") | |
607 | 663 | } | |
608 | 664 | } | |
627 | 683 | } | |
628 | 684 | } | |
629 | 685 | let currentRewardEntryNew = { | |
630 | - | let $ | |
631 | - | let $ | |
632 | - | let $ | |
633 | - | if (($ | |
634 | - | then $ | |
686 | + | let $list1338413430 = currentPools | |
687 | + | let $size1338413430 = size($list1338413430) | |
688 | + | let $acc01338413430 = nil | |
689 | + | if (($size1338413430 == 0)) | |
690 | + | then $acc01338413430 | |
635 | 691 | else { | |
636 | - | let $ | |
637 | - | if (($ | |
638 | - | then $ | |
692 | + | let $acc11338413430 = CurrentRewardEntry($acc01338413430, $list1338413430[0]) | |
693 | + | if (($size1338413430 == 1)) | |
694 | + | then $acc11338413430 | |
639 | 695 | else { | |
640 | - | let $ | |
641 | - | if (($ | |
642 | - | then $ | |
696 | + | let $acc21338413430 = CurrentRewardEntry($acc11338413430, $list1338413430[1]) | |
697 | + | if (($size1338413430 == 2)) | |
698 | + | then $acc21338413430 | |
643 | 699 | else { | |
644 | - | let $ | |
645 | - | if (($ | |
646 | - | then $ | |
700 | + | let $acc31338413430 = CurrentRewardEntry($acc21338413430, $list1338413430[2]) | |
701 | + | if (($size1338413430 == 3)) | |
702 | + | then $acc31338413430 | |
647 | 703 | else { | |
648 | - | let $ | |
649 | - | if (($ | |
650 | - | then $ | |
704 | + | let $acc41338413430 = CurrentRewardEntry($acc31338413430, $list1338413430[3]) | |
705 | + | if (($size1338413430 == 4)) | |
706 | + | then $acc41338413430 | |
651 | 707 | else { | |
652 | - | let $ | |
653 | - | if (($ | |
654 | - | then $ | |
708 | + | let $acc51338413430 = CurrentRewardEntry($acc41338413430, $list1338413430[4]) | |
709 | + | if (($size1338413430 == 5)) | |
710 | + | then $acc51338413430 | |
655 | 711 | else { | |
656 | - | let $ | |
657 | - | if (($ | |
658 | - | then $ | |
712 | + | let $acc61338413430 = CurrentRewardEntry($acc51338413430, $list1338413430[5]) | |
713 | + | if (($size1338413430 == 6)) | |
714 | + | then $acc61338413430 | |
659 | 715 | else { | |
660 | - | let $ | |
661 | - | if (($ | |
662 | - | then $ | |
716 | + | let $acc71338413430 = CurrentRewardEntry($acc61338413430, $list1338413430[6]) | |
717 | + | if (($size1338413430 == 7)) | |
718 | + | then $acc71338413430 | |
663 | 719 | else { | |
664 | - | let $ | |
665 | - | if (($ | |
666 | - | then $ | |
720 | + | let $acc81338413430 = CurrentRewardEntry($acc71338413430, $list1338413430[7]) | |
721 | + | if (($size1338413430 == 8)) | |
722 | + | then $acc81338413430 | |
667 | 723 | else { | |
668 | - | let $ | |
669 | - | if (($ | |
670 | - | then $ | |
724 | + | let $acc91338413430 = CurrentRewardEntry($acc81338413430, $list1338413430[8]) | |
725 | + | if (($size1338413430 == 9)) | |
726 | + | then $acc91338413430 | |
671 | 727 | else { | |
672 | - | let $ | |
673 | - | if (($ | |
674 | - | then $ | |
728 | + | let $acc101338413430 = CurrentRewardEntry($acc91338413430, $list1338413430[9]) | |
729 | + | if (($size1338413430 == 10)) | |
730 | + | then $acc101338413430 | |
675 | 731 | else { | |
676 | - | let $ | |
677 | - | if (($ | |
678 | - | then $ | |
732 | + | let $acc111338413430 = CurrentRewardEntry($acc101338413430, $list1338413430[10]) | |
733 | + | if (($size1338413430 == 11)) | |
734 | + | then $acc111338413430 | |
679 | 735 | else { | |
680 | - | let $ | |
681 | - | if (($ | |
682 | - | then $ | |
736 | + | let $acc121338413430 = CurrentRewardEntry($acc111338413430, $list1338413430[11]) | |
737 | + | if (($size1338413430 == 12)) | |
738 | + | then $acc121338413430 | |
683 | 739 | else { | |
684 | - | let $ | |
685 | - | if (($ | |
686 | - | then $ | |
740 | + | let $acc131338413430 = CurrentRewardEntry($acc121338413430, $list1338413430[12]) | |
741 | + | if (($size1338413430 == 13)) | |
742 | + | then $acc131338413430 | |
687 | 743 | else { | |
688 | - | let $ | |
689 | - | if (($ | |
690 | - | then $ | |
744 | + | let $acc141338413430 = CurrentRewardEntry($acc131338413430, $list1338413430[13]) | |
745 | + | if (($size1338413430 == 14)) | |
746 | + | then $acc141338413430 | |
691 | 747 | else { | |
692 | - | let $ | |
693 | - | if (($ | |
694 | - | then $ | |
748 | + | let $acc151338413430 = CurrentRewardEntry($acc141338413430, $list1338413430[14]) | |
749 | + | if (($size1338413430 == 15)) | |
750 | + | then $acc151338413430 | |
695 | 751 | else { | |
696 | - | let $ | |
697 | - | if (($ | |
698 | - | then $ | |
752 | + | let $acc161338413430 = CurrentRewardEntry($acc151338413430, $list1338413430[15]) | |
753 | + | if (($size1338413430 == 16)) | |
754 | + | then $acc161338413430 | |
699 | 755 | else { | |
700 | - | let $ | |
701 | - | if (($ | |
702 | - | then $ | |
756 | + | let $acc171338413430 = CurrentRewardEntry($acc161338413430, $list1338413430[16]) | |
757 | + | if (($size1338413430 == 17)) | |
758 | + | then $acc171338413430 | |
703 | 759 | else { | |
704 | - | let $ | |
705 | - | if (($ | |
706 | - | then $ | |
760 | + | let $acc181338413430 = CurrentRewardEntry($acc171338413430, $list1338413430[17]) | |
761 | + | if (($size1338413430 == 18)) | |
762 | + | then $acc181338413430 | |
707 | 763 | else { | |
708 | - | let $ | |
709 | - | if (($ | |
710 | - | then $ | |
764 | + | let $acc191338413430 = CurrentRewardEntry($acc181338413430, $list1338413430[18]) | |
765 | + | if (($size1338413430 == 19)) | |
766 | + | then $acc191338413430 | |
711 | 767 | else { | |
712 | - | let $ | |
713 | - | if (($ | |
714 | - | then $ | |
768 | + | let $acc201338413430 = CurrentRewardEntry($acc191338413430, $list1338413430[19]) | |
769 | + | if (($size1338413430 == 20)) | |
770 | + | then $acc201338413430 | |
715 | 771 | else { | |
716 | - | let $ | |
772 | + | let $acc211338413430 = CurrentRewardEntry($acc201338413430, $list1338413430[20]) | |
717 | 773 | throw("List size exceed 20") | |
718 | 774 | } | |
719 | 775 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 4 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let adminPubKey1 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
5 | 5 | ||
6 | 6 | let adminPubKey2 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
7 | 7 | ||
8 | 8 | let adminPubKey3 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
9 | 9 | ||
10 | 10 | let adminPubKeyStartStop = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
11 | 11 | ||
12 | 12 | let adminPubKeyWallet = base58'5CqqMkmtXXt35KRH9LdWA3ap6TffPvTT5SHQzYrVFbBw' | |
13 | 13 | ||
14 | 14 | let keyActive = "active" | |
15 | 15 | ||
16 | 16 | let keyCause = "shutdown_cause" | |
17 | 17 | ||
18 | 18 | let keyLastInterest = "last_interest" | |
19 | 19 | ||
20 | 20 | let keyUserLastInterest = "_last_interest" | |
21 | 21 | ||
22 | 22 | let keyUserSWOPLocked = "_SWOP_amount" | |
23 | 23 | ||
24 | 24 | let keyUserGetBackHeight = "_getBackHeight" | |
25 | 25 | ||
26 | 26 | let keyTotalSWOPLocked = "total_SWOP_amount" | |
27 | 27 | ||
28 | 28 | let kUserTotalVoteSWOP = "_user_total_SWOP_vote" | |
29 | 29 | ||
30 | 30 | let keyUserVoteOptionAmount = "_SWOP_option_amount" | |
31 | 31 | ||
32 | 32 | let keyTotalVoteOptionAmount = "total_SWOP_option_amount" | |
33 | 33 | ||
34 | 34 | let keyUserSWOPClaimedAmount = "_SWOP_claimed_amount" | |
35 | 35 | ||
36 | 36 | let keyUserSWOPLastClaimedAmount = "_SWOP_last_claimed_amount" | |
37 | 37 | ||
38 | 38 | let keyVoteName = "vote_name" | |
39 | 39 | ||
40 | 40 | let keyOptionName = "_option_name" | |
41 | 41 | ||
42 | 42 | let keyVotingStartHeight = "_startHeight" | |
43 | 43 | ||
44 | 44 | let keyVoteDuration = "_vote_duration" | |
45 | 45 | ||
46 | 46 | let keyRewardPoolFractionCurrent = "_current_pool_fraction_reward" | |
47 | 47 | ||
48 | 48 | let keyRewardPoolFractionPrevious = "_previous_pool_fraction_reward" | |
49 | 49 | ||
50 | 50 | let keyTotalRewardPerBlockCurrent = "total_reward_per_block_current" | |
51 | 51 | ||
52 | 52 | let keyTotalRewardPerBlockPrevious = "total_reward_per_block_previous" | |
53 | 53 | ||
54 | 54 | let keyRewardUpdateHeight = "reward_update_height" | |
55 | 55 | ||
56 | 56 | let isActive = valueOrElse(getBoolean(this, keyActive), true) | |
57 | 57 | ||
58 | 58 | let farmingSWOPAddress = Address(base58'3MsjAKkxKjxVU4gC1BpJ1jKmAZyRufUCErC') | |
59 | 59 | ||
60 | 60 | let votingLiteContract = Address(base58'3N6CYoCsxrcXKe75pQvvV3JqJrwJjm1t4QN') | |
61 | 61 | ||
62 | 62 | let keySWOPid = "SWOP_id" | |
63 | 63 | ||
64 | 64 | let SWOP = fromBase58String(getStringValue(farmingSWOPAddress, keySWOPid)) | |
65 | 65 | ||
66 | 66 | let scaleValue = 100000000 | |
67 | 67 | ||
68 | 68 | let totalVoteShare = 10000000000 | |
69 | 69 | ||
70 | + | let kStartHeight = "start_height" | |
71 | + | ||
72 | + | let kBasePeriod = "base_period" | |
73 | + | ||
74 | + | let kPeriodLength = "period_length" | |
75 | + | ||
76 | + | let kUserTotalStruc = "_user_total_struc" | |
77 | + | ||
78 | + | let basePeriod = valueOrErrorMessage(getInteger(votingLiteContract, kBasePeriod), "Empty kBasePeriod at voting contract") | |
79 | + | ||
80 | + | let startHeight = valueOrErrorMessage(getInteger(votingLiteContract, kStartHeight), "Empty kStartHeight at voting contract") | |
81 | + | ||
82 | + | let periodLength = valueOrErrorMessage(getInteger(votingLiteContract, kPeriodLength), "Empty kPeriodLength at voting contract") | |
83 | + | ||
84 | + | let currVotingPeriod = (basePeriod + ((height - startHeight) / periodLength)) | |
85 | + | ||
70 | 86 | func suspend (cause) = [BooleanEntry(keyActive, false), StringEntry(keyCause, cause)] | |
71 | 87 | ||
72 | 88 | ||
73 | 89 | func throwNotEnoughSWOP () = throw("Not enough SWOP: userSWOPLocked - userTotalVoteAmount < voteSWOPAmount") | |
74 | 90 | ||
75 | 91 | ||
76 | 92 | func getLastInterestInfo () = { | |
77 | 93 | let lastInterest = valueOrElse(getInteger(this, keyLastInterest), 0) | |
78 | 94 | lastInterest | |
79 | 95 | } | |
80 | 96 | ||
81 | 97 | ||
82 | 98 | func getUserSWOPLocked (user) = valueOrElse(getInteger(this, (toString(user) + keyUserSWOPLocked)), 0) | |
83 | 99 | ||
84 | 100 | ||
85 | 101 | func getUserSWOPClaimedAmount (user) = valueOrElse(getInteger(this, (toString(user) + keyUserSWOPClaimedAmount)), 0) | |
86 | 102 | ||
87 | 103 | ||
88 | 104 | func getUserInterestInfo (user,lastInterest) = { | |
89 | 105 | let userSWOPAmount = getUserSWOPLocked(user) | |
90 | 106 | let userLastInterest = getInteger(this, (toString(user) + keyUserLastInterest)) | |
91 | 107 | let userLastInterestValue = match userLastInterest { | |
92 | 108 | case userLastInterest: Int => | |
93 | 109 | userLastInterest | |
94 | 110 | case _ => | |
95 | 111 | lastInterest | |
96 | 112 | } | |
97 | 113 | $Tuple2(userLastInterestValue, userSWOPAmount) | |
98 | 114 | } | |
99 | 115 | ||
100 | 116 | ||
101 | 117 | func getTotalSWOPLocked () = valueOrElse(getInteger(this, keyTotalSWOPLocked), 0) | |
102 | 118 | ||
103 | 119 | ||
104 | - | func getUserTotalVoteAmount (user) = valueOrElse(getInteger(votingLiteContract, (toString(user) + kUserTotalVoteSWOP)), 0) | |
120 | + | func getUserUnvoteAmount (user) = { | |
121 | + | let $t037844323 = if (isDefined(getString(this, (toString(user) + kUserTotalStruc)))) | |
122 | + | then { | |
123 | + | let data = split(valueOrErrorMessage(getString(votingLiteContract, (toString(user) + kUserTotalStruc)), "Empty kUserTotalStruc"), "_") | |
124 | + | $Tuple3(parseIntValue(data[0]), parseIntValue(data[1]), parseIntValue(data[2])) | |
125 | + | } | |
126 | + | else { | |
127 | + | let uPoolTotalSWOP = valueOrElse(getInteger(votingLiteContract, (toString(user) + kUserTotalVoteSWOP)), 0) | |
128 | + | $Tuple3(uPoolTotalSWOP, 0, currVotingPeriod) | |
129 | + | } | |
130 | + | let userTotalVoteSWOP = $t037844323._1 | |
131 | + | let userUnvoted = $t037844323._2 | |
132 | + | let userUnvotedPeriod = $t037844323._3 | |
133 | + | if ((userUnvotedPeriod == currVotingPeriod)) | |
134 | + | then userUnvoted | |
135 | + | else 0 | |
136 | + | } | |
105 | 137 | ||
106 | 138 | ||
107 | 139 | func getUserVoteOptionAmount (user) = valueOrElse(getInteger(this, (toString(user) + keyUserVoteOptionAmount)), 0) | |
108 | 140 | ||
109 | 141 | ||
110 | 142 | func getVotingStartHeight (voteName) = valueOrElse(getInteger(this, (voteName + keyVotingStartHeight)), 0) | |
111 | 143 | ||
112 | 144 | ||
113 | 145 | func getVoteOptionAmount (user,voteName,option) = { | |
114 | 146 | let userVoteOptionAmount = getInteger(this, (((voteName + option) + toString(user)) + keyUserVoteOptionAmount)) | |
115 | 147 | let uvoa = match userVoteOptionAmount { | |
116 | 148 | case uvoa: Int => | |
117 | 149 | uvoa | |
118 | 150 | case uvoa: Unit => | |
119 | 151 | 0 | |
120 | 152 | case _ => | |
121 | 153 | throw("Match error") | |
122 | 154 | } | |
123 | 155 | valueOrErrorMessage(uvoa, (((("No data on the key: " + voteName) + option) + toString(user)) + keyUserVoteOptionAmount)) | |
124 | 156 | } | |
125 | 157 | ||
126 | 158 | ||
127 | 159 | func getVoteDuration (voteName) = valueOrErrorMessage(getInteger(this, (voteName + keyVoteDuration)), (("No data on the key: " + voteName) + keyVoteDuration)) | |
128 | 160 | ||
129 | 161 | ||
130 | 162 | func getTotalVoteOptionAmount (voteName,option) = { | |
131 | 163 | let totalVoteOptionAmount = getInteger(this, ((voteName + option) + keyTotalVoteOptionAmount)) | |
132 | 164 | let tvoa = match totalVoteOptionAmount { | |
133 | 165 | case tvoa: Int => | |
134 | 166 | tvoa | |
135 | 167 | case tvoa: Unit => | |
136 | 168 | 0 | |
137 | 169 | case _ => | |
138 | 170 | throw("Match error") | |
139 | 171 | } | |
140 | 172 | tvoa | |
141 | 173 | } | |
142 | 174 | ||
143 | 175 | ||
176 | + | func getUserTotalVoteAmount (user) = { | |
177 | + | let $t057096220 = if (isDefined(getString(this, (toString(user) + kUserTotalStruc)))) | |
178 | + | then { | |
179 | + | let data = split(valueOrErrorMessage(getString(this, (toString(user) + kUserTotalStruc)), "Empty kUserTotalStruc"), "_") | |
180 | + | $Tuple3(parseIntValue(data[0]), parseIntValue(data[1]), parseIntValue(data[2])) | |
181 | + | } | |
182 | + | else { | |
183 | + | let uPoolTotalSWOP = valueOrElse(getInteger(this, (toString(user) + kUserTotalVoteSWOP)), 0) | |
184 | + | $Tuple3(uPoolTotalSWOP, 0, currVotingPeriod) | |
185 | + | } | |
186 | + | let userTotalVoteSWOP = $t057096220._1 | |
187 | + | let userUnvoted = $t057096220._2 | |
188 | + | let userUnvotedPeriod = $t057096220._3 | |
189 | + | userTotalVoteSWOP | |
190 | + | } | |
191 | + | ||
192 | + | ||
144 | 193 | func getUserGetBackAmount (voteName,option,user,getBackSWOPHeight) = { | |
145 | 194 | let key = ((((((voteName + "_") + option) + "_") + toString(user)) + "_") + toString(getBackSWOPHeight)) | |
146 | 195 | valueOrErrorMessage(getInteger(this, key), ("No data on the key: " + key)) | |
147 | 196 | } | |
148 | 197 | ||
149 | 198 | ||
150 | 199 | func claimCalc (caller) = { | |
151 | 200 | let lastInterest = getLastInterestInfo() | |
152 | - | let $ | |
153 | - | let userLastInterest = $ | |
154 | - | let userSWOPLocked = $ | |
201 | + | let $t066556735 = getUserInterestInfo(caller, lastInterest) | |
202 | + | let userLastInterest = $t066556735._1 | |
203 | + | let userSWOPLocked = $t066556735._2 | |
155 | 204 | let claimAmount = fraction(userSWOPLocked, (lastInterest - userLastInterest), scaleValue) | |
156 | 205 | let userNewInterest = lastInterest | |
157 | 206 | $Tuple2(userNewInterest, claimAmount) | |
158 | 207 | } | |
159 | 208 | ||
160 | 209 | ||
161 | 210 | @Callable(i) | |
162 | 211 | func airDrop () = if (!(isActive)) | |
163 | 212 | then throw("DApp is inactive at this moment") | |
164 | 213 | else { | |
165 | - | let $ | |
166 | - | let pmtAmount = $ | |
167 | - | let pmtAssetId = $ | |
214 | + | let $t070007075 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
215 | + | let pmtAmount = $t070007075._1 | |
216 | + | let pmtAssetId = $t070007075._2 | |
168 | 217 | if ((pmtAssetId != SWOP)) | |
169 | 218 | then throw("Incorrect pmtAssetId") | |
170 | 219 | else { | |
171 | 220 | let totalSWOPLocked = getTotalSWOPLocked() | |
172 | 221 | let lastInterest = getLastInterestInfo() | |
173 | 222 | let interestNew = (lastInterest + fraction(pmtAmount, scaleValue, totalSWOPLocked)) | |
174 | 223 | [IntegerEntry(keyLastInterest, interestNew)] | |
175 | 224 | } | |
176 | 225 | } | |
177 | 226 | ||
178 | 227 | ||
179 | 228 | ||
180 | 229 | @Callable(i) | |
181 | 230 | func lockSWOP () = if (!(isActive)) | |
182 | 231 | then throw("DApp is inactive at this moment") | |
183 | 232 | else { | |
184 | - | let $ | |
185 | - | let pmtAmount = $ | |
186 | - | let pmtAssetId = $ | |
233 | + | let $t075137588 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
234 | + | let pmtAmount = $t075137588._1 | |
235 | + | let pmtAssetId = $t075137588._2 | |
187 | 236 | if ((pmtAssetId != SWOP)) | |
188 | 237 | then throw("Incorrect pmtAssetId") | |
189 | 238 | else { | |
190 | 239 | let lastInterest = getLastInterestInfo() | |
191 | - | let $ | |
192 | - | let userLastInterest = $ | |
193 | - | let userSWOPLocked = $ | |
240 | + | let $t077047786 = getUserInterestInfo(i.caller, lastInterest) | |
241 | + | let userLastInterest = $t077047786._1 | |
242 | + | let userSWOPLocked = $t077047786._2 | |
194 | 243 | let claimAmount = fraction(userSWOPLocked, (lastInterest - userLastInterest), scaleValue) | |
195 | 244 | let userSWOPLockedNew = ((userSWOPLocked + pmtAmount) + claimAmount) | |
196 | 245 | let userNewInterest = lastInterest | |
197 | 246 | let totalSWOPLocked = getTotalSWOPLocked() | |
198 | 247 | let totalSWOPLockedNew = ((totalSWOPLocked + pmtAmount) + claimAmount) | |
199 | 248 | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
200 | 249 | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
201 | 250 | [IntegerEntry((toString(i.caller) + keyUserLastInterest), userNewInterest), IntegerEntry((toString(i.caller) + keyUserSWOPLocked), userSWOPLockedNew), IntegerEntry(keyTotalSWOPLocked, totalSWOPLockedNew), IntegerEntry((toString(i.caller) + keyUserSWOPClaimedAmount), userClaimedAmountNew), IntegerEntry((toString(i.caller) + keyUserSWOPLastClaimedAmount), claimAmount)] | |
202 | 251 | } | |
203 | 252 | } | |
204 | 253 | ||
205 | 254 | ||
206 | 255 | ||
207 | 256 | @Callable(i) | |
208 | 257 | func withdrawSWOP (withdrawAmount) = if (!(isActive)) | |
209 | 258 | then throw("DApp is inactive at this moment") | |
210 | 259 | else { | |
211 | 260 | let totalSWOPLocked = getTotalSWOPLocked() | |
212 | 261 | let userSWOPLocked = getUserSWOPLocked(i.caller) | |
213 | - | let $ | |
214 | - | let userNewInterest = $ | |
215 | - | let claimAmount = $ | |
262 | + | let $t088708925 = claimCalc(i.caller) | |
263 | + | let userNewInterest = $t088708925._1 | |
264 | + | let claimAmount = $t088708925._2 | |
216 | 265 | let userVoteAmount = getUserTotalVoteAmount(i.caller) | |
217 | - | let availableFund = (userSWOPLocked - userVoteAmount) | |
218 | - | if ((withdrawAmount > availableFund)) | |
219 | - | then throw("withdrawAmount > availableFund") | |
266 | + | let userUnvoteAmount = getUserUnvoteAmount(i.caller) | |
267 | + | if (if ((0 > userUnvoteAmount)) | |
268 | + | then true | |
269 | + | else (0 > userVoteAmount)) | |
270 | + | then throw("userUnvoteAmount < 0 || userVoteAmount < 0") | |
220 | 271 | else { | |
221 | - | let totalSWOPLockedNew = ((totalSWOPLocked + claimAmount) - withdrawAmount) | |
222 | - | let userSWOPamountNew = ((userSWOPLocked + claimAmount) - withdrawAmount) | |
223 | - | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
224 | - | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
272 | + | let availableToUnstake = ((userSWOPLocked - userVoteAmount) - userUnvoteAmount) | |
273 | + | if ((withdrawAmount > availableToUnstake)) | |
274 | + | then throw("withdrawAmount > availableToUnstake") | |
275 | + | else { | |
276 | + | let totalSWOPLockedNew = ((totalSWOPLocked + claimAmount) - withdrawAmount) | |
277 | + | let userSWOPamountNew = ((userSWOPLocked + claimAmount) - withdrawAmount) | |
278 | + | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
279 | + | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
225 | 280 | [IntegerEntry((toString(i.caller) + keyUserLastInterest), userNewInterest), IntegerEntry((toString(i.caller) + keyUserSWOPLocked), userSWOPamountNew), IntegerEntry(keyTotalSWOPLocked, totalSWOPLockedNew), ScriptTransfer(i.caller, withdrawAmount, SWOP), IntegerEntry((toString(i.caller) + keyUserSWOPClaimedAmount), userClaimedAmountNew), IntegerEntry((toString(i.caller) + keyUserSWOPLastClaimedAmount), claimAmount)] | |
281 | + | } | |
226 | 282 | } | |
227 | 283 | } | |
228 | 284 | ||
229 | 285 | ||
230 | 286 | ||
231 | 287 | @Callable(i) | |
232 | 288 | func claimAndWithdrawSWOP () = if (!(isActive)) | |
233 | 289 | then throw("DApp is inactive at this moment") | |
234 | 290 | else { | |
235 | 291 | let lastInterest = getLastInterestInfo() | |
236 | - | let $ | |
237 | - | let userNewInterest = $ | |
238 | - | let claimAmount = $ | |
292 | + | let $t01024110296 = claimCalc(i.caller) | |
293 | + | let userNewInterest = $t01024110296._1 | |
294 | + | let claimAmount = $t01024110296._2 | |
239 | 295 | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
240 | 296 | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
241 | 297 | if ((claimAmount == 0)) | |
242 | 298 | then throw("You have 0 available SWOP") | |
243 | 299 | else [IntegerEntry((toString(i.caller) + keyUserLastInterest), userNewInterest), IntegerEntry((toString(i.caller) + keyUserSWOPClaimedAmount), userClaimedAmountNew), IntegerEntry((toString(i.caller) + keyUserSWOPLastClaimedAmount), claimAmount), ScriptTransfer(i.caller, claimAmount, SWOP)] | |
244 | 300 | } | |
245 | 301 | ||
246 | 302 | ||
247 | 303 | ||
248 | 304 | @Callable(i) | |
249 | 305 | func claimAndStakeSWOP () = if (!(isActive)) | |
250 | 306 | then throw("DApp is inactive at this moment") | |
251 | 307 | else { | |
252 | 308 | let totalSWOPLocked = getTotalSWOPLocked() | |
253 | 309 | let userSWOPLocked = getUserSWOPLocked(i.caller) | |
254 | 310 | let lastInterest = getLastInterestInfo() | |
255 | - | let $ | |
256 | - | let userNewInterest = $ | |
257 | - | let claimAmount = $ | |
311 | + | let $t01107511130 = claimCalc(i.caller) | |
312 | + | let userNewInterest = $t01107511130._1 | |
313 | + | let claimAmount = $t01107511130._2 | |
258 | 314 | let userSWOPLockedNew = (userSWOPLocked + claimAmount) | |
259 | 315 | let totalSWOPLockedNew = (totalSWOPLocked + claimAmount) | |
260 | 316 | let userClaimedAmount = getUserSWOPClaimedAmount(i.caller) | |
261 | 317 | let userClaimedAmountNew = (userClaimedAmount + claimAmount) | |
262 | 318 | if ((claimAmount == 0)) | |
263 | 319 | then throw("You have 0 available SWOP") | |
264 | 320 | else [IntegerEntry((toString(i.caller) + keyUserLastInterest), userNewInterest), IntegerEntry(keyTotalSWOPLocked, totalSWOPLockedNew), IntegerEntry((toString(i.caller) + keyUserSWOPLocked), userSWOPLockedNew), IntegerEntry((toString(i.caller) + keyUserSWOPClaimedAmount), userClaimedAmountNew), IntegerEntry((toString(i.caller) + keyUserSWOPLastClaimedAmount), claimAmount)] | |
265 | 321 | } | |
266 | 322 | ||
267 | 323 | ||
268 | 324 | ||
269 | 325 | @Callable(i) | |
270 | 326 | func updateWeights (previousPools,previousRewards,currentPools,currentRewards,rewardUpdateHeight) = if (!(isActive)) | |
271 | 327 | then throw("DApp is inactive at this moment") | |
272 | - | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop | |
328 | + | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop], i.callerPublicKey))) | |
273 | 329 | then throw("Only admin can call this function") | |
274 | 330 | else { | |
275 | 331 | func sum (a,b) = (a + b) | |
276 | 332 | ||
277 | 333 | func PreviousRewardEntry (accumulated,pool) = { | |
278 | 334 | let poolIndex = value(indexOf(previousPools, pool)) | |
279 | 335 | let poolReward = previousRewards[poolIndex] | |
280 | 336 | IntegerEntry((pool + keyRewardPoolFractionPrevious), poolReward) :: accumulated | |
281 | 337 | } | |
282 | 338 | ||
283 | 339 | func CurrentRewardEntry (accumulated,pool) = { | |
284 | 340 | let poolIndex = value(indexOf(currentPools, pool)) | |
285 | 341 | let poolReward = currentRewards[poolIndex] | |
286 | 342 | IntegerEntry((pool + keyRewardPoolFractionCurrent), poolReward) :: accumulated | |
287 | 343 | } | |
288 | 344 | ||
289 | 345 | let sumRewardPrevious = { | |
290 | - | let $ | |
291 | - | let $ | |
292 | - | let $ | |
293 | - | if (($ | |
294 | - | then $ | |
346 | + | let $list1289712930 = previousRewards | |
347 | + | let $size1289712930 = size($list1289712930) | |
348 | + | let $acc01289712930 = 0 | |
349 | + | if (($size1289712930 == 0)) | |
350 | + | then $acc01289712930 | |
295 | 351 | else { | |
296 | - | let $ | |
297 | - | if (($ | |
298 | - | then $ | |
352 | + | let $acc11289712930 = sum($acc01289712930, $list1289712930[0]) | |
353 | + | if (($size1289712930 == 1)) | |
354 | + | then $acc11289712930 | |
299 | 355 | else { | |
300 | - | let $ | |
301 | - | if (($ | |
302 | - | then $ | |
356 | + | let $acc21289712930 = sum($acc11289712930, $list1289712930[1]) | |
357 | + | if (($size1289712930 == 2)) | |
358 | + | then $acc21289712930 | |
303 | 359 | else { | |
304 | - | let $ | |
305 | - | if (($ | |
306 | - | then $ | |
360 | + | let $acc31289712930 = sum($acc21289712930, $list1289712930[2]) | |
361 | + | if (($size1289712930 == 3)) | |
362 | + | then $acc31289712930 | |
307 | 363 | else { | |
308 | - | let $ | |
309 | - | if (($ | |
310 | - | then $ | |
364 | + | let $acc41289712930 = sum($acc31289712930, $list1289712930[3]) | |
365 | + | if (($size1289712930 == 4)) | |
366 | + | then $acc41289712930 | |
311 | 367 | else { | |
312 | - | let $ | |
313 | - | if (($ | |
314 | - | then $ | |
368 | + | let $acc51289712930 = sum($acc41289712930, $list1289712930[4]) | |
369 | + | if (($size1289712930 == 5)) | |
370 | + | then $acc51289712930 | |
315 | 371 | else { | |
316 | - | let $ | |
317 | - | if (($ | |
318 | - | then $ | |
372 | + | let $acc61289712930 = sum($acc51289712930, $list1289712930[5]) | |
373 | + | if (($size1289712930 == 6)) | |
374 | + | then $acc61289712930 | |
319 | 375 | else { | |
320 | - | let $ | |
321 | - | if (($ | |
322 | - | then $ | |
376 | + | let $acc71289712930 = sum($acc61289712930, $list1289712930[6]) | |
377 | + | if (($size1289712930 == 7)) | |
378 | + | then $acc71289712930 | |
323 | 379 | else { | |
324 | - | let $ | |
325 | - | if (($ | |
326 | - | then $ | |
380 | + | let $acc81289712930 = sum($acc71289712930, $list1289712930[7]) | |
381 | + | if (($size1289712930 == 8)) | |
382 | + | then $acc81289712930 | |
327 | 383 | else { | |
328 | - | let $ | |
329 | - | if (($ | |
330 | - | then $ | |
384 | + | let $acc91289712930 = sum($acc81289712930, $list1289712930[8]) | |
385 | + | if (($size1289712930 == 9)) | |
386 | + | then $acc91289712930 | |
331 | 387 | else { | |
332 | - | let $ | |
333 | - | if (($ | |
334 | - | then $ | |
388 | + | let $acc101289712930 = sum($acc91289712930, $list1289712930[9]) | |
389 | + | if (($size1289712930 == 10)) | |
390 | + | then $acc101289712930 | |
335 | 391 | else { | |
336 | - | let $ | |
337 | - | if (($ | |
338 | - | then $ | |
392 | + | let $acc111289712930 = sum($acc101289712930, $list1289712930[10]) | |
393 | + | if (($size1289712930 == 11)) | |
394 | + | then $acc111289712930 | |
339 | 395 | else { | |
340 | - | let $ | |
341 | - | if (($ | |
342 | - | then $ | |
396 | + | let $acc121289712930 = sum($acc111289712930, $list1289712930[11]) | |
397 | + | if (($size1289712930 == 12)) | |
398 | + | then $acc121289712930 | |
343 | 399 | else { | |
344 | - | let $ | |
345 | - | if (($ | |
346 | - | then $ | |
400 | + | let $acc131289712930 = sum($acc121289712930, $list1289712930[12]) | |
401 | + | if (($size1289712930 == 13)) | |
402 | + | then $acc131289712930 | |
347 | 403 | else { | |
348 | - | let $ | |
349 | - | if (($ | |
350 | - | then $ | |
404 | + | let $acc141289712930 = sum($acc131289712930, $list1289712930[13]) | |
405 | + | if (($size1289712930 == 14)) | |
406 | + | then $acc141289712930 | |
351 | 407 | else { | |
352 | - | let $ | |
353 | - | if (($ | |
354 | - | then $ | |
408 | + | let $acc151289712930 = sum($acc141289712930, $list1289712930[14]) | |
409 | + | if (($size1289712930 == 15)) | |
410 | + | then $acc151289712930 | |
355 | 411 | else { | |
356 | - | let $ | |
357 | - | if (($ | |
358 | - | then $ | |
412 | + | let $acc161289712930 = sum($acc151289712930, $list1289712930[15]) | |
413 | + | if (($size1289712930 == 16)) | |
414 | + | then $acc161289712930 | |
359 | 415 | else { | |
360 | - | let $ | |
361 | - | if (($ | |
362 | - | then $ | |
416 | + | let $acc171289712930 = sum($acc161289712930, $list1289712930[16]) | |
417 | + | if (($size1289712930 == 17)) | |
418 | + | then $acc171289712930 | |
363 | 419 | else { | |
364 | - | let $ | |
365 | - | if (($ | |
366 | - | then $ | |
420 | + | let $acc181289712930 = sum($acc171289712930, $list1289712930[17]) | |
421 | + | if (($size1289712930 == 18)) | |
422 | + | then $acc181289712930 | |
367 | 423 | else { | |
368 | - | let $ | |
369 | - | if (($ | |
370 | - | then $ | |
424 | + | let $acc191289712930 = sum($acc181289712930, $list1289712930[18]) | |
425 | + | if (($size1289712930 == 19)) | |
426 | + | then $acc191289712930 | |
371 | 427 | else { | |
372 | - | let $ | |
373 | - | if (($ | |
374 | - | then $ | |
428 | + | let $acc201289712930 = sum($acc191289712930, $list1289712930[19]) | |
429 | + | if (($size1289712930 == 20)) | |
430 | + | then $acc201289712930 | |
375 | 431 | else { | |
376 | - | let $ | |
432 | + | let $acc211289712930 = sum($acc201289712930, $list1289712930[20]) | |
377 | 433 | throw("List size exceed 20") | |
378 | 434 | } | |
379 | 435 | } | |
380 | 436 | } | |
381 | 437 | } | |
382 | 438 | } | |
383 | 439 | } | |
384 | 440 | } | |
385 | 441 | } | |
386 | 442 | } | |
387 | 443 | } | |
388 | 444 | } | |
389 | 445 | } | |
390 | 446 | } | |
391 | 447 | } | |
392 | 448 | } | |
393 | 449 | } | |
394 | 450 | } | |
395 | 451 | } | |
396 | 452 | } | |
397 | 453 | } | |
398 | 454 | } | |
399 | 455 | } | |
400 | 456 | let sumRewardCurrent = { | |
401 | - | let $ | |
402 | - | let $ | |
403 | - | let $ | |
404 | - | if (($ | |
405 | - | then $ | |
457 | + | let $list1295912991 = currentRewards | |
458 | + | let $size1295912991 = size($list1295912991) | |
459 | + | let $acc01295912991 = 0 | |
460 | + | if (($size1295912991 == 0)) | |
461 | + | then $acc01295912991 | |
406 | 462 | else { | |
407 | - | let $ | |
408 | - | if (($ | |
409 | - | then $ | |
463 | + | let $acc11295912991 = sum($acc01295912991, $list1295912991[0]) | |
464 | + | if (($size1295912991 == 1)) | |
465 | + | then $acc11295912991 | |
410 | 466 | else { | |
411 | - | let $ | |
412 | - | if (($ | |
413 | - | then $ | |
467 | + | let $acc21295912991 = sum($acc11295912991, $list1295912991[1]) | |
468 | + | if (($size1295912991 == 2)) | |
469 | + | then $acc21295912991 | |
414 | 470 | else { | |
415 | - | let $ | |
416 | - | if (($ | |
417 | - | then $ | |
471 | + | let $acc31295912991 = sum($acc21295912991, $list1295912991[2]) | |
472 | + | if (($size1295912991 == 3)) | |
473 | + | then $acc31295912991 | |
418 | 474 | else { | |
419 | - | let $ | |
420 | - | if (($ | |
421 | - | then $ | |
475 | + | let $acc41295912991 = sum($acc31295912991, $list1295912991[3]) | |
476 | + | if (($size1295912991 == 4)) | |
477 | + | then $acc41295912991 | |
422 | 478 | else { | |
423 | - | let $ | |
424 | - | if (($ | |
425 | - | then $ | |
479 | + | let $acc51295912991 = sum($acc41295912991, $list1295912991[4]) | |
480 | + | if (($size1295912991 == 5)) | |
481 | + | then $acc51295912991 | |
426 | 482 | else { | |
427 | - | let $ | |
428 | - | if (($ | |
429 | - | then $ | |
483 | + | let $acc61295912991 = sum($acc51295912991, $list1295912991[5]) | |
484 | + | if (($size1295912991 == 6)) | |
485 | + | then $acc61295912991 | |
430 | 486 | else { | |
431 | - | let $ | |
432 | - | if (($ | |
433 | - | then $ | |
487 | + | let $acc71295912991 = sum($acc61295912991, $list1295912991[6]) | |
488 | + | if (($size1295912991 == 7)) | |
489 | + | then $acc71295912991 | |
434 | 490 | else { | |
435 | - | let $ | |
436 | - | if (($ | |
437 | - | then $ | |
491 | + | let $acc81295912991 = sum($acc71295912991, $list1295912991[7]) | |
492 | + | if (($size1295912991 == 8)) | |
493 | + | then $acc81295912991 | |
438 | 494 | else { | |
439 | - | let $ | |
440 | - | if (($ | |
441 | - | then $ | |
495 | + | let $acc91295912991 = sum($acc81295912991, $list1295912991[8]) | |
496 | + | if (($size1295912991 == 9)) | |
497 | + | then $acc91295912991 | |
442 | 498 | else { | |
443 | - | let $ | |
444 | - | if (($ | |
445 | - | then $ | |
499 | + | let $acc101295912991 = sum($acc91295912991, $list1295912991[9]) | |
500 | + | if (($size1295912991 == 10)) | |
501 | + | then $acc101295912991 | |
446 | 502 | else { | |
447 | - | let $ | |
448 | - | if (($ | |
449 | - | then $ | |
503 | + | let $acc111295912991 = sum($acc101295912991, $list1295912991[10]) | |
504 | + | if (($size1295912991 == 11)) | |
505 | + | then $acc111295912991 | |
450 | 506 | else { | |
451 | - | let $ | |
452 | - | if (($ | |
453 | - | then $ | |
507 | + | let $acc121295912991 = sum($acc111295912991, $list1295912991[11]) | |
508 | + | if (($size1295912991 == 12)) | |
509 | + | then $acc121295912991 | |
454 | 510 | else { | |
455 | - | let $ | |
456 | - | if (($ | |
457 | - | then $ | |
511 | + | let $acc131295912991 = sum($acc121295912991, $list1295912991[12]) | |
512 | + | if (($size1295912991 == 13)) | |
513 | + | then $acc131295912991 | |
458 | 514 | else { | |
459 | - | let $ | |
460 | - | if (($ | |
461 | - | then $ | |
515 | + | let $acc141295912991 = sum($acc131295912991, $list1295912991[13]) | |
516 | + | if (($size1295912991 == 14)) | |
517 | + | then $acc141295912991 | |
462 | 518 | else { | |
463 | - | let $ | |
464 | - | if (($ | |
465 | - | then $ | |
519 | + | let $acc151295912991 = sum($acc141295912991, $list1295912991[14]) | |
520 | + | if (($size1295912991 == 15)) | |
521 | + | then $acc151295912991 | |
466 | 522 | else { | |
467 | - | let $ | |
468 | - | if (($ | |
469 | - | then $ | |
523 | + | let $acc161295912991 = sum($acc151295912991, $list1295912991[15]) | |
524 | + | if (($size1295912991 == 16)) | |
525 | + | then $acc161295912991 | |
470 | 526 | else { | |
471 | - | let $ | |
472 | - | if (($ | |
473 | - | then $ | |
527 | + | let $acc171295912991 = sum($acc161295912991, $list1295912991[16]) | |
528 | + | if (($size1295912991 == 17)) | |
529 | + | then $acc171295912991 | |
474 | 530 | else { | |
475 | - | let $ | |
476 | - | if (($ | |
477 | - | then $ | |
531 | + | let $acc181295912991 = sum($acc171295912991, $list1295912991[17]) | |
532 | + | if (($size1295912991 == 18)) | |
533 | + | then $acc181295912991 | |
478 | 534 | else { | |
479 | - | let $ | |
480 | - | if (($ | |
481 | - | then $ | |
535 | + | let $acc191295912991 = sum($acc181295912991, $list1295912991[18]) | |
536 | + | if (($size1295912991 == 19)) | |
537 | + | then $acc191295912991 | |
482 | 538 | else { | |
483 | - | let $ | |
484 | - | if (($ | |
485 | - | then $ | |
539 | + | let $acc201295912991 = sum($acc191295912991, $list1295912991[19]) | |
540 | + | if (($size1295912991 == 20)) | |
541 | + | then $acc201295912991 | |
486 | 542 | else { | |
487 | - | let $ | |
543 | + | let $acc211295912991 = sum($acc201295912991, $list1295912991[20]) | |
488 | 544 | throw("List size exceed 20") | |
489 | 545 | } | |
490 | 546 | } | |
491 | 547 | } | |
492 | 548 | } | |
493 | 549 | } | |
494 | 550 | } | |
495 | 551 | } | |
496 | 552 | } | |
497 | 553 | } | |
498 | 554 | } | |
499 | 555 | } | |
500 | 556 | } | |
501 | 557 | } | |
502 | 558 | } | |
503 | 559 | } | |
504 | 560 | } | |
505 | 561 | } | |
506 | 562 | } | |
507 | 563 | } | |
508 | 564 | } | |
509 | 565 | } | |
510 | 566 | } | |
511 | 567 | if ((height > rewardUpdateHeight)) | |
512 | 568 | then throw("rewardUpdateHeight < height") | |
513 | 569 | else if (if ((sumRewardPrevious != totalVoteShare)) | |
514 | 570 | then true | |
515 | 571 | else (sumRewardCurrent != totalVoteShare)) | |
516 | 572 | then throw("sumRewardPrevious != totalVoteShare or sumRewardCurrent != totalVoteShare") | |
517 | 573 | else { | |
518 | 574 | let previousRewardEntryNew = { | |
519 | - | let $ | |
520 | - | let $ | |
521 | - | let $ | |
522 | - | if (($ | |
523 | - | then $ | |
575 | + | let $list1330313351 = previousPools | |
576 | + | let $size1330313351 = size($list1330313351) | |
577 | + | let $acc01330313351 = nil | |
578 | + | if (($size1330313351 == 0)) | |
579 | + | then $acc01330313351 | |
524 | 580 | else { | |
525 | - | let $ | |
526 | - | if (($ | |
527 | - | then $ | |
581 | + | let $acc11330313351 = PreviousRewardEntry($acc01330313351, $list1330313351[0]) | |
582 | + | if (($size1330313351 == 1)) | |
583 | + | then $acc11330313351 | |
528 | 584 | else { | |
529 | - | let $ | |
530 | - | if (($ | |
531 | - | then $ | |
585 | + | let $acc21330313351 = PreviousRewardEntry($acc11330313351, $list1330313351[1]) | |
586 | + | if (($size1330313351 == 2)) | |
587 | + | then $acc21330313351 | |
532 | 588 | else { | |
533 | - | let $ | |
534 | - | if (($ | |
535 | - | then $ | |
589 | + | let $acc31330313351 = PreviousRewardEntry($acc21330313351, $list1330313351[2]) | |
590 | + | if (($size1330313351 == 3)) | |
591 | + | then $acc31330313351 | |
536 | 592 | else { | |
537 | - | let $ | |
538 | - | if (($ | |
539 | - | then $ | |
593 | + | let $acc41330313351 = PreviousRewardEntry($acc31330313351, $list1330313351[3]) | |
594 | + | if (($size1330313351 == 4)) | |
595 | + | then $acc41330313351 | |
540 | 596 | else { | |
541 | - | let $ | |
542 | - | if (($ | |
543 | - | then $ | |
597 | + | let $acc51330313351 = PreviousRewardEntry($acc41330313351, $list1330313351[4]) | |
598 | + | if (($size1330313351 == 5)) | |
599 | + | then $acc51330313351 | |
544 | 600 | else { | |
545 | - | let $ | |
546 | - | if (($ | |
547 | - | then $ | |
601 | + | let $acc61330313351 = PreviousRewardEntry($acc51330313351, $list1330313351[5]) | |
602 | + | if (($size1330313351 == 6)) | |
603 | + | then $acc61330313351 | |
548 | 604 | else { | |
549 | - | let $ | |
550 | - | if (($ | |
551 | - | then $ | |
605 | + | let $acc71330313351 = PreviousRewardEntry($acc61330313351, $list1330313351[6]) | |
606 | + | if (($size1330313351 == 7)) | |
607 | + | then $acc71330313351 | |
552 | 608 | else { | |
553 | - | let $ | |
554 | - | if (($ | |
555 | - | then $ | |
609 | + | let $acc81330313351 = PreviousRewardEntry($acc71330313351, $list1330313351[7]) | |
610 | + | if (($size1330313351 == 8)) | |
611 | + | then $acc81330313351 | |
556 | 612 | else { | |
557 | - | let $ | |
558 | - | if (($ | |
559 | - | then $ | |
613 | + | let $acc91330313351 = PreviousRewardEntry($acc81330313351, $list1330313351[8]) | |
614 | + | if (($size1330313351 == 9)) | |
615 | + | then $acc91330313351 | |
560 | 616 | else { | |
561 | - | let $ | |
562 | - | if (($ | |
563 | - | then $ | |
617 | + | let $acc101330313351 = PreviousRewardEntry($acc91330313351, $list1330313351[9]) | |
618 | + | if (($size1330313351 == 10)) | |
619 | + | then $acc101330313351 | |
564 | 620 | else { | |
565 | - | let $ | |
566 | - | if (($ | |
567 | - | then $ | |
621 | + | let $acc111330313351 = PreviousRewardEntry($acc101330313351, $list1330313351[10]) | |
622 | + | if (($size1330313351 == 11)) | |
623 | + | then $acc111330313351 | |
568 | 624 | else { | |
569 | - | let $ | |
570 | - | if (($ | |
571 | - | then $ | |
625 | + | let $acc121330313351 = PreviousRewardEntry($acc111330313351, $list1330313351[11]) | |
626 | + | if (($size1330313351 == 12)) | |
627 | + | then $acc121330313351 | |
572 | 628 | else { | |
573 | - | let $ | |
574 | - | if (($ | |
575 | - | then $ | |
629 | + | let $acc131330313351 = PreviousRewardEntry($acc121330313351, $list1330313351[12]) | |
630 | + | if (($size1330313351 == 13)) | |
631 | + | then $acc131330313351 | |
576 | 632 | else { | |
577 | - | let $ | |
578 | - | if (($ | |
579 | - | then $ | |
633 | + | let $acc141330313351 = PreviousRewardEntry($acc131330313351, $list1330313351[13]) | |
634 | + | if (($size1330313351 == 14)) | |
635 | + | then $acc141330313351 | |
580 | 636 | else { | |
581 | - | let $ | |
582 | - | if (($ | |
583 | - | then $ | |
637 | + | let $acc151330313351 = PreviousRewardEntry($acc141330313351, $list1330313351[14]) | |
638 | + | if (($size1330313351 == 15)) | |
639 | + | then $acc151330313351 | |
584 | 640 | else { | |
585 | - | let $ | |
586 | - | if (($ | |
587 | - | then $ | |
641 | + | let $acc161330313351 = PreviousRewardEntry($acc151330313351, $list1330313351[15]) | |
642 | + | if (($size1330313351 == 16)) | |
643 | + | then $acc161330313351 | |
588 | 644 | else { | |
589 | - | let $ | |
590 | - | if (($ | |
591 | - | then $ | |
645 | + | let $acc171330313351 = PreviousRewardEntry($acc161330313351, $list1330313351[16]) | |
646 | + | if (($size1330313351 == 17)) | |
647 | + | then $acc171330313351 | |
592 | 648 | else { | |
593 | - | let $ | |
594 | - | if (($ | |
595 | - | then $ | |
649 | + | let $acc181330313351 = PreviousRewardEntry($acc171330313351, $list1330313351[17]) | |
650 | + | if (($size1330313351 == 18)) | |
651 | + | then $acc181330313351 | |
596 | 652 | else { | |
597 | - | let $ | |
598 | - | if (($ | |
599 | - | then $ | |
653 | + | let $acc191330313351 = PreviousRewardEntry($acc181330313351, $list1330313351[18]) | |
654 | + | if (($size1330313351 == 19)) | |
655 | + | then $acc191330313351 | |
600 | 656 | else { | |
601 | - | let $ | |
602 | - | if (($ | |
603 | - | then $ | |
657 | + | let $acc201330313351 = PreviousRewardEntry($acc191330313351, $list1330313351[19]) | |
658 | + | if (($size1330313351 == 20)) | |
659 | + | then $acc201330313351 | |
604 | 660 | else { | |
605 | - | let $ | |
661 | + | let $acc211330313351 = PreviousRewardEntry($acc201330313351, $list1330313351[20]) | |
606 | 662 | throw("List size exceed 20") | |
607 | 663 | } | |
608 | 664 | } | |
609 | 665 | } | |
610 | 666 | } | |
611 | 667 | } | |
612 | 668 | } | |
613 | 669 | } | |
614 | 670 | } | |
615 | 671 | } | |
616 | 672 | } | |
617 | 673 | } | |
618 | 674 | } | |
619 | 675 | } | |
620 | 676 | } | |
621 | 677 | } | |
622 | 678 | } | |
623 | 679 | } | |
624 | 680 | } | |
625 | 681 | } | |
626 | 682 | } | |
627 | 683 | } | |
628 | 684 | } | |
629 | 685 | let currentRewardEntryNew = { | |
630 | - | let $ | |
631 | - | let $ | |
632 | - | let $ | |
633 | - | if (($ | |
634 | - | then $ | |
686 | + | let $list1338413430 = currentPools | |
687 | + | let $size1338413430 = size($list1338413430) | |
688 | + | let $acc01338413430 = nil | |
689 | + | if (($size1338413430 == 0)) | |
690 | + | then $acc01338413430 | |
635 | 691 | else { | |
636 | - | let $ | |
637 | - | if (($ | |
638 | - | then $ | |
692 | + | let $acc11338413430 = CurrentRewardEntry($acc01338413430, $list1338413430[0]) | |
693 | + | if (($size1338413430 == 1)) | |
694 | + | then $acc11338413430 | |
639 | 695 | else { | |
640 | - | let $ | |
641 | - | if (($ | |
642 | - | then $ | |
696 | + | let $acc21338413430 = CurrentRewardEntry($acc11338413430, $list1338413430[1]) | |
697 | + | if (($size1338413430 == 2)) | |
698 | + | then $acc21338413430 | |
643 | 699 | else { | |
644 | - | let $ | |
645 | - | if (($ | |
646 | - | then $ | |
700 | + | let $acc31338413430 = CurrentRewardEntry($acc21338413430, $list1338413430[2]) | |
701 | + | if (($size1338413430 == 3)) | |
702 | + | then $acc31338413430 | |
647 | 703 | else { | |
648 | - | let $ | |
649 | - | if (($ | |
650 | - | then $ | |
704 | + | let $acc41338413430 = CurrentRewardEntry($acc31338413430, $list1338413430[3]) | |
705 | + | if (($size1338413430 == 4)) | |
706 | + | then $acc41338413430 | |
651 | 707 | else { | |
652 | - | let $ | |
653 | - | if (($ | |
654 | - | then $ | |
708 | + | let $acc51338413430 = CurrentRewardEntry($acc41338413430, $list1338413430[4]) | |
709 | + | if (($size1338413430 == 5)) | |
710 | + | then $acc51338413430 | |
655 | 711 | else { | |
656 | - | let $ | |
657 | - | if (($ | |
658 | - | then $ | |
712 | + | let $acc61338413430 = CurrentRewardEntry($acc51338413430, $list1338413430[5]) | |
713 | + | if (($size1338413430 == 6)) | |
714 | + | then $acc61338413430 | |
659 | 715 | else { | |
660 | - | let $ | |
661 | - | if (($ | |
662 | - | then $ | |
716 | + | let $acc71338413430 = CurrentRewardEntry($acc61338413430, $list1338413430[6]) | |
717 | + | if (($size1338413430 == 7)) | |
718 | + | then $acc71338413430 | |
663 | 719 | else { | |
664 | - | let $ | |
665 | - | if (($ | |
666 | - | then $ | |
720 | + | let $acc81338413430 = CurrentRewardEntry($acc71338413430, $list1338413430[7]) | |
721 | + | if (($size1338413430 == 8)) | |
722 | + | then $acc81338413430 | |
667 | 723 | else { | |
668 | - | let $ | |
669 | - | if (($ | |
670 | - | then $ | |
724 | + | let $acc91338413430 = CurrentRewardEntry($acc81338413430, $list1338413430[8]) | |
725 | + | if (($size1338413430 == 9)) | |
726 | + | then $acc91338413430 | |
671 | 727 | else { | |
672 | - | let $ | |
673 | - | if (($ | |
674 | - | then $ | |
728 | + | let $acc101338413430 = CurrentRewardEntry($acc91338413430, $list1338413430[9]) | |
729 | + | if (($size1338413430 == 10)) | |
730 | + | then $acc101338413430 | |
675 | 731 | else { | |
676 | - | let $ | |
677 | - | if (($ | |
678 | - | then $ | |
732 | + | let $acc111338413430 = CurrentRewardEntry($acc101338413430, $list1338413430[10]) | |
733 | + | if (($size1338413430 == 11)) | |
734 | + | then $acc111338413430 | |
679 | 735 | else { | |
680 | - | let $ | |
681 | - | if (($ | |
682 | - | then $ | |
736 | + | let $acc121338413430 = CurrentRewardEntry($acc111338413430, $list1338413430[11]) | |
737 | + | if (($size1338413430 == 12)) | |
738 | + | then $acc121338413430 | |
683 | 739 | else { | |
684 | - | let $ | |
685 | - | if (($ | |
686 | - | then $ | |
740 | + | let $acc131338413430 = CurrentRewardEntry($acc121338413430, $list1338413430[12]) | |
741 | + | if (($size1338413430 == 13)) | |
742 | + | then $acc131338413430 | |
687 | 743 | else { | |
688 | - | let $ | |
689 | - | if (($ | |
690 | - | then $ | |
744 | + | let $acc141338413430 = CurrentRewardEntry($acc131338413430, $list1338413430[13]) | |
745 | + | if (($size1338413430 == 14)) | |
746 | + | then $acc141338413430 | |
691 | 747 | else { | |
692 | - | let $ | |
693 | - | if (($ | |
694 | - | then $ | |
748 | + | let $acc151338413430 = CurrentRewardEntry($acc141338413430, $list1338413430[14]) | |
749 | + | if (($size1338413430 == 15)) | |
750 | + | then $acc151338413430 | |
695 | 751 | else { | |
696 | - | let $ | |
697 | - | if (($ | |
698 | - | then $ | |
752 | + | let $acc161338413430 = CurrentRewardEntry($acc151338413430, $list1338413430[15]) | |
753 | + | if (($size1338413430 == 16)) | |
754 | + | then $acc161338413430 | |
699 | 755 | else { | |
700 | - | let $ | |
701 | - | if (($ | |
702 | - | then $ | |
756 | + | let $acc171338413430 = CurrentRewardEntry($acc161338413430, $list1338413430[16]) | |
757 | + | if (($size1338413430 == 17)) | |
758 | + | then $acc171338413430 | |
703 | 759 | else { | |
704 | - | let $ | |
705 | - | if (($ | |
706 | - | then $ | |
760 | + | let $acc181338413430 = CurrentRewardEntry($acc171338413430, $list1338413430[17]) | |
761 | + | if (($size1338413430 == 18)) | |
762 | + | then $acc181338413430 | |
707 | 763 | else { | |
708 | - | let $ | |
709 | - | if (($ | |
710 | - | then $ | |
764 | + | let $acc191338413430 = CurrentRewardEntry($acc181338413430, $list1338413430[18]) | |
765 | + | if (($size1338413430 == 19)) | |
766 | + | then $acc191338413430 | |
711 | 767 | else { | |
712 | - | let $ | |
713 | - | if (($ | |
714 | - | then $ | |
768 | + | let $acc201338413430 = CurrentRewardEntry($acc191338413430, $list1338413430[19]) | |
769 | + | if (($size1338413430 == 20)) | |
770 | + | then $acc201338413430 | |
715 | 771 | else { | |
716 | - | let $ | |
772 | + | let $acc211338413430 = CurrentRewardEntry($acc201338413430, $list1338413430[20]) | |
717 | 773 | throw("List size exceed 20") | |
718 | 774 | } | |
719 | 775 | } | |
720 | 776 | } | |
721 | 777 | } | |
722 | 778 | } | |
723 | 779 | } | |
724 | 780 | } | |
725 | 781 | } | |
726 | 782 | } | |
727 | 783 | } | |
728 | 784 | } | |
729 | 785 | } | |
730 | 786 | } | |
731 | 787 | } | |
732 | 788 | } | |
733 | 789 | } | |
734 | 790 | } | |
735 | 791 | } | |
736 | 792 | } | |
737 | 793 | } | |
738 | 794 | } | |
739 | 795 | } | |
740 | 796 | ((previousRewardEntryNew ++ currentRewardEntryNew) ++ [IntegerEntry(keyRewardUpdateHeight, rewardUpdateHeight)]) | |
741 | 797 | } | |
742 | 798 | } | |
743 | 799 | ||
744 | 800 | ||
745 | 801 | ||
746 | 802 | @Callable(i) | |
747 | 803 | func shutdown () = if (!(isActive)) | |
748 | 804 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, keyCause), "the cause wasn't specified"))) | |
749 | 805 | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop], i.callerPublicKey))) | |
750 | 806 | then throw("Only admin can call this function") | |
751 | 807 | else suspend("Paused by admin") | |
752 | 808 | ||
753 | 809 | ||
754 | 810 | ||
755 | 811 | @Callable(i) | |
756 | 812 | func activate () = if (isActive) | |
757 | 813 | then throw("DApp is already active") | |
758 | 814 | else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminPubKeyStartStop], i.callerPublicKey))) | |
759 | 815 | then throw("Only admin can call this function") | |
760 | 816 | else [BooleanEntry(keyActive, true), DeleteEntry(keyCause)] | |
761 | 817 | ||
762 | 818 | ||
763 | 819 | @Verifier(tx) | |
764 | 820 | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
765 | 821 |
github/deemru/w8io/169f3d6 927.89 ms ◑