tx · GSPTD42ZfJuujPW4kMVGFUbmJF82gZzGM2p1WJ26e4mc

3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr:  -0.02700000 Waves

2024.04.17 09:53 [3066439] smart account 3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr > SELF 0.00000000 Waves

{ "type": 13, "id": "GSPTD42ZfJuujPW4kMVGFUbmJF82gZzGM2p1WJ26e4mc", "fee": 2700000, "feeAssetId": null, "timestamp": 1713336857481, "version": 2, "chainId": 84, "sender": "3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr", "senderPublicKey": "GFbasS3jufhZkK4xR7tdTjjnP8K33KvJFEDHRtxXDkaJ", "proofs": [ "4XddkDre4cFYKTDXkJCyhNhAPWU8dZ9vn3TJR6Y9ziKJKbksQnGZhEZHzGgzHsY6Np4vnnGyUKuSvbKnLtzYzgbZ" ], "script": "base64:BgK/GggCEgQKAggBEgcKBQgICAgBEgQKAggIEgUKAwgIARIECgIICBIDCgEBEgMKAQESAwoBCBIECgIICBIECgIIBBIAEgMKAQESABIECgIICBIECgIICBIECgIICBIAEgQKAggIEgQKAggIIglzZXBhcmF0b3IiDnBvb2xXZWlnaHRNdWx0Ig9tYXhEZXB0aERlZmF1bHQiGWZpbmFsaXphdGlvblN0YWdlQmFsYW5jZXMiFmZpbmFsaXphdGlvblN0YWdlVG90YWwiF2ZpbmFsaXphdGlvblN0YWdlU2hhcmVzIhRyZXN1bXB0aW9uRmVlRGVmYXVsdCIOa2V5RXBvY2hMZW5ndGgiEWtleUVwb2NoTGVuZ3RoTmV3IhVrZXlFcG9jaExlbmd0aEJ5RXBvY2giBWVwb2NoIg9rZXlDdXJyZW50RXBvY2giC2tleU1heERlcHRoIhBrZXlSZXN1bXB0aW9uRmVlIiJrZXlWb3RpbmdFbWlzc2lvbkNhbmRpZGF0ZUNvbnRyYWN0Ih1rZXlWb3RpbmdFbWlzc2lvblJhdGVDb250cmFjdCISa2V5RmFjdG9yeUNvbnR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x1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgkAAgECJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgECZGEBAmRiAAQCZGMEAmFlCQECYmgAAwkAAQIFAmFlAgpCeXRlVmVjdG9yBAJibAUCYWUFAmJsAwkAAQIFAmFlAgRVbml0CAUCZGEPc2VuZGVyUHVibGljS2V5CQACAQILTWF0Y2ggZXJyb3IJAPQDAwgFAmRhCWJvZHlCeXRlcwkAkQMCCAUCZGEGcHJvb2ZzAAAFAmRjF+lq2w==", "height": 3066439, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GGrxUtyWStFqoWpfsizaH2df2wUuz1wdjQGdkBjksJVx Next: HMhuth8E4erWybLPu7ULFa7bpB7QgAw6YLn3amCMAga4 Diff:
OldNewDifferences
997997 else throwErr("both assets should be verified")]
998998 if ((checks == checks))
999999 then {
1000- let pool = $Tuple2(amountAssetId, priceAssetId)
1001- let inListActions = ([BooleanEntry(keyInList(pool), true)] ++ insertNodeActions(poolsListName, poolToString(pool)))
1002- $Tuple2(inListActions, unit)
1000+ let setWxEmissionInv = invoke(factoryContract, "setWxEmissionPoolLabel", [amountAssetId, priceAssetId], nil)
1001+ if ((setWxEmissionInv == setWxEmissionInv))
1002+ then {
1003+ let pool = $Tuple2(amountAssetId, priceAssetId)
1004+ let inListActions = ([BooleanEntry(keyInList(pool), true)] ++ insertNodeActions(poolsListName, poolToString(pool)))
1005+ $Tuple2(inListActions, unit)
1006+ }
1007+ else throw("Strict value is not equal to itself.")
10031008 }
10041009 else throw("Strict value is not equal to itself.")
10051010 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let separator = "__"
55
66 let poolWeightMult = 100000000
77
88 let maxDepthDefault = 10
99
1010 let finalizationStageBalances = 0
1111
1212 let finalizationStageTotal = 1
1313
1414 let finalizationStageShares = 2
1515
1616 let resumptionFeeDefault = 500000000000
1717
1818 let keyEpochLength = makeString(["%s", "epochLength"], separator)
1919
2020 let keyEpochLengthNew = makeString(["%s%s", "epochLength__new"], separator)
2121
2222 func keyEpochLengthByEpoch (epoch) = makeString(["%s%d", "epochLength", toString(epoch)], separator)
2323
2424
2525 let keyCurrentEpoch = makeString(["%s", "currentEpoch"], separator)
2626
2727 let keyMaxDepth = makeString(["%s", "maxDepth"], separator)
2828
2929 let keyResumptionFee = makeString(["%s", "resumptionFee"], separator)
3030
3131 let keyVotingEmissionCandidateContract = makeString(["%s", "votingEmissionCandidateContract"], separator)
3232
3333 let keyVotingEmissionRateContract = makeString(["%s", "votingEmissionRateContract"], separator)
3434
3535 let keyFactoryContract = makeString(["%s", "factoryContract"], separator)
3636
3737 let keyBoostingContract = makeString(["%s", "boostingContract"], separator)
3838
3939 let keyStakingContract = makeString(["%s", "stakingContract"], separator)
4040
4141 let keyAssetsStoreContract = makeString(["%s", "assetsStoreContract"], separator)
4242
4343 let keyFinalizationStage = makeString(["%s", "finalizationStage"], separator)
4444
4545 let keyNextPool = makeString(["%s", "nextPool"], separator)
4646
4747 let keyNextUser = makeString(["%s", "nextUser"], separator)
4848
4949 let keyStartHeight = makeString(["%s", "startHeight"], separator)
5050
5151 let keyCurrentEpochUi = makeString(["%s", "currentEpochUi"], separator)
5252
5353 let keyStartHeightUi = makeString(["%s", "startHeightUi"], separator)
5454
5555 let keyFinalizationShouldBeForced = makeString(["%s", "force"], separator)
5656
5757 func keyStartHeightByEpoch (epoch) = makeString(["%s%d", "startHeight", toString(epoch)], separator)
5858
5959
6060 func keyFinalized (epoch) = makeString(["%s%d", "finalized", toString(epoch)], separator)
6161
6262
6363 func keyInList (pool) = {
6464 let $t020132053 = pool
6565 let amountAssetId = $t020132053._1
6666 let priceAssetId = $t020132053._2
6767 makeString(["%s%s%s", "inList", amountAssetId, priceAssetId], separator)
6868 }
6969
7070
7171 func keyInsufficientBalances (pool,epoch) = {
7272 let $t022022242 = pool
7373 let amountAssetId = $t022022242._1
7474 let priceAssetId = $t022022242._2
7575 makeString(["%s%s%s%d", "insufficientBalances", amountAssetId, priceAssetId, toString(epoch)], separator)
7676 }
7777
7878
7979 func keyUsed (address,epoch) = makeString(["%s%s%d", "used", toString(address), toString(epoch)], separator)
8080
8181
8282 func keyVote (pool,address,epoch) = {
8383 let $t025502590 = pool
8484 let amountAssetId = $t025502590._1
8585 let priceAssetId = $t025502590._2
8686 makeString(["%s%s%s%s%d", "vote", amountAssetId, priceAssetId, toString(address), toString(epoch)], separator)
8787 }
8888
8989
9090 func keyVotingResult (pool,epoch) = {
9191 let $t027722812 = pool
9292 let amountAssetId = $t027722812._1
9393 let priceAssetId = $t027722812._2
9494 makeString(["%s%s%s%d", "votingResult", amountAssetId, priceAssetId, toString(epoch)], separator)
9595 }
9696
9797
9898 func keyVotingResultStaked (lpAssetIdStr,epoch) = makeString(["%s%s%d", "votingResultStaked", lpAssetIdStr, toString(epoch)], separator)
9999
100100
101101 func keyPoolShare (pool,epoch) = {
102102 let $t031333173 = pool
103103 let amountAssetId = $t031333173._1
104104 let priceAssetId = $t031333173._2
105105 makeString(["%s%s%s%d", "poolShare", amountAssetId, priceAssetId, toString(epoch)], separator)
106106 }
107107
108108
109109 func keyTotalVotes (epoch) = makeString(["%s%d", "totalVotes", toString(epoch)], separator)
110110
111111
112112 func keyStakedByUser (lpAssetIdStr,userAddressStr) = makeString(["%s%s%s", "staked", userAddressStr, lpAssetIdStr], separator)
113113
114114
115115 func wrapErr (msg) = makeString(["voting_emission.ride:", msg], " ")
116116
117117
118118 func throwErr (msg) = throw(wrapErr(msg))
119119
120120
121121 func getValueOrFail (address,key,type) = {
122122 let error = wrapErr(makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
123123 valueOrErrorMessage( match type {
124124 case str: String =>
125125 getString(address, key)
126126 case int: Int =>
127127 getInteger(address, key)
128128 case _ =>
129129 throwErr("invalid entry type")
130130 }, error)
131131 }
132132
133133
134134 func getStrOrFail (address,key) = {
135135 let @ = getValueOrFail(address, key, "")
136136 if ($isInstanceOf(@, "String"))
137137 then @
138138 else throw(($getType(@) + " couldn't be cast to String"))
139139 }
140140
141141
142142 func getIntOrFail (address,key) = {
143143 let @ = getValueOrFail(address, key, 0)
144144 if ($isInstanceOf(@, "Int"))
145145 then @
146146 else throw(($getType(@) + " couldn't be cast to Int"))
147147 }
148148
149149
150150 func poolToString (pool) = ((pool._1 + separator) + pool._2)
151151
152152
153153 func stringToPool (str) = {
154154 let parts = split(str, separator)
155155 if ((size(parts) == 2))
156156 then $Tuple2(parts[0], parts[1])
157157 else throwErr("invalid pool string")
158158 }
159159
160160
161161 let factoryContract = addressFromStringValue(getStrOrFail(this, keyFactoryContract))
162162
163163 let IdxFactoryCfgGwxRewardDapp = 10
164164
165165 func keyFactoryCfg () = "%s__factoryConfig"
166166
167167
168168 func readFactoryCfgOrFail (factory) = split(getStrOrFail(factory, keyFactoryCfg()), separator)
169169
170170
171171 func getGwxRewardAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgGwxRewardDapp])
172172
173173
174174 func getPoolInfo (amountAssetId,priceAssetId) = {
175175 let poolInfoOption = {
176176 let @ = invoke(factoryContract, "poolInfoREADONLY", [amountAssetId, priceAssetId], nil)
177177 if ($isInstanceOf(@, "(Address, ByteVector)"))
178178 then @
179179 else unit
180180 }
181181 poolInfoOption
182182 }
183183
184184
185185 func getLpAssetByPoolAssets (amountAssetId,priceAssetId) = {
186186 func keyMappingsBaseAsset2internalId (baseAssetStr) = ("%s%s%s__mappings__baseAsset2internalId__" + baseAssetStr)
187187
188188 func keyMappingPoolAssetsToPoolContractAddress (internalAmountAssetIdStr,internalPriceAssetIdStr) = (((("%d%d%s%s__" + toString(internalAmountAssetIdStr)) + "__") + toString(internalPriceAssetIdStr)) + "__mappings__poolAssets2PoolContract")
189189
190190 func keyMappingPoolContractToLPAsset (poolContractAddress) = (("%s%s%s__" + poolContractAddress) + "__mappings__poolContract2LpAsset")
191191
192192 let amountAssetInternalId = getIntOrFail(factoryContract, keyMappingsBaseAsset2internalId(amountAssetId))
193193 let priceAssetInternalId = getIntOrFail(factoryContract, keyMappingsBaseAsset2internalId(priceAssetId))
194194 let poolContractAddress = getStrOrFail(factoryContract, keyMappingPoolAssetsToPoolContractAddress(amountAssetInternalId, priceAssetInternalId))
195195 let lpAssetId = getStrOrFail(factoryContract, keyMappingPoolContractToLPAsset(poolContractAddress))
196196 lpAssetId
197197 }
198198
199199
200200 func checkWxEmissionPoolLabel (pool) = {
201201 let $t062996339 = pool
202202 let amountAssetId = $t062996339._1
203203 let priceAssetId = $t062996339._2
204204 let @ = invoke(factoryContract, "checkWxEmissionPoolLabel", [amountAssetId, priceAssetId], nil)
205205 if ($isInstanceOf(@, "Boolean"))
206206 then @
207207 else throw(($getType(@) + " couldn't be cast to Boolean"))
208208 }
209209
210210
211211 func gwxRewardDeposit () = {
212212 let factoryCfg = readFactoryCfgOrFail(factoryContract)
213213 let gwxRewardsContract = getGwxRewardAddressOrFail(factoryCfg)
214214 invoke(gwxRewardsContract, "deposit", nil, nil)
215215 }
216216
217217
218218 let poolsListName = "pools"
219219
220220 func getVotesListName (pool) = {
221221 let $t067566796 = pool
222222 let amountAssetId = $t067566796._1
223223 let priceAssetId = $t067566796._2
224224 makeString(["votes", amountAssetId, priceAssetId], separator)
225225 }
226226
227227
228228 func keyListHead (listName) = {
229229 let meta = if ((listName == poolsListName))
230230 then "%s%s"
231231 else "%s%s%s%s"
232232 makeString([meta, listName, "head"], separator)
233233 }
234234
235235
236236 func keyListSize (listName) = {
237237 let meta = if ((listName == poolsListName))
238238 then "%s%s"
239239 else "%s%s%s%s"
240240 makeString([meta, listName, "size"], separator)
241241 }
242242
243243
244244 func keyListPrev (listName,id) = {
245245 let meta = if ((listName == poolsListName))
246246 then "%s%s%s%s"
247247 else "%s%s%s%s%s"
248248 makeString([meta, listName, id, "prev"], separator)
249249 }
250250
251251
252252 func keyListNext (listName,id) = {
253253 let meta = if ((listName == poolsListName))
254254 then "%s%s%s%s"
255255 else "%s%s%s%s%s"
256256 makeString([meta, listName, id, "next"], separator)
257257 }
258258
259259
260260 func containsNode (listName,id) = {
261261 let headOrUnit = getString(this, keyListHead(listName))
262262 let prevOrUnit = getString(this, keyListPrev(listName, id))
263263 let nextOrUnit = getString(this, keyListNext(listName, id))
264264 if (if ((id == valueOrElse(headOrUnit, "")))
265265 then true
266266 else (prevOrUnit != unit))
267267 then true
268268 else (nextOrUnit != unit)
269269 }
270270
271271
272272 func insertNodeActions (listName,id) = {
273273 let headOrUnit = getString(this, keyListHead(listName))
274274 let listSize = valueOrElse(getInteger(this, keyListSize(listName)), 0)
275275 let checkNode = if (!(containsNode(listName, id)))
276276 then true
277277 else throwErr("Node exists")
278278 if ((checkNode == checkNode))
279279 then (([IntegerEntry(keyListSize(listName), (listSize + 1))] ++ (if ((headOrUnit != unit))
280280 then [StringEntry(keyListNext(listName, id), value(headOrUnit)), StringEntry(keyListPrev(listName, value(headOrUnit)), id)]
281281 else nil)) ++ [StringEntry(keyListHead(listName), id)])
282282 else throw("Strict value is not equal to itself.")
283283 }
284284
285285
286286 func deleteNodeActions (listName,id) = {
287287 let headOrUnit = getString(this, keyListHead(listName))
288288 let listSize = valueOrElse(getInteger(this, keyListSize(listName)), 0)
289289 let prevOrUnit = getString(this, keyListPrev(listName, id))
290290 let nextOrUnit = getString(this, keyListNext(listName, id))
291291 ([IntegerEntry(keyListSize(listName), (listSize - 1))] ++ (if (if ((prevOrUnit != unit))
292292 then (nextOrUnit != unit)
293293 else false)
294294 then [StringEntry(keyListNext(listName, value(prevOrUnit)), value(nextOrUnit)), StringEntry(keyListPrev(listName, value(nextOrUnit)), value(prevOrUnit)), DeleteEntry(keyListPrev(listName, id)), DeleteEntry(keyListNext(listName, id))]
295295 else if ((nextOrUnit != unit))
296296 then [StringEntry(keyListHead(listName), value(nextOrUnit)), DeleteEntry(keyListNext(listName, id)), DeleteEntry(keyListPrev(listName, value(nextOrUnit)))]
297297 else if ((prevOrUnit != unit))
298298 then [DeleteEntry(keyListPrev(listName, id)), DeleteEntry(keyListNext(listName, value(prevOrUnit)))]
299299 else if ((id == valueOrElse(headOrUnit, "")))
300300 then [DeleteEntry(keyListHead(listName))]
301301 else throwErr(((("invalid node: " + listName) + ".") + id))))
302302 }
303303
304304
305305 func keyManagerVaultAddress () = "%s__managerVaultAddress"
306306
307307
308308 func keyManagerPublicKey () = "%s__managerPublicKey"
309309
310310
311311 func getManagerVaultAddressOrThis () = match getString(keyManagerVaultAddress()) {
312312 case s: String =>
313313 addressFromStringValue(s)
314314 case _ =>
315315 this
316316 }
317317
318318
319319 func managerPublicKeyOrUnit () = {
320320 let managerVaultAddress = getManagerVaultAddressOrThis()
321321 match getString(managerVaultAddress, keyManagerPublicKey()) {
322322 case s: String =>
323323 fromBase58String(s)
324324 case _: Unit =>
325325 unit
326326 case _ =>
327327 throw("Match error")
328328 }
329329 }
330330
331331
332332 func isManager (i) = match managerPublicKeyOrUnit() {
333333 case pk: ByteVector =>
334334 (i.callerPublicKey == pk)
335335 case _: Unit =>
336336 (i.caller == this)
337337 case _ =>
338338 throw("Match error")
339339 }
340340
341341
342342 func mustManager (i) = if (isManager(i))
343343 then true
344344 else throw("permission denied")
345345
346346
347347 func mustThis (i) = if ((i.caller == this))
348348 then true
349349 else throw("permission denied")
350350
351351
352352 @Callable(i)
353353 func getUserGwxAmountAtHeight (userAddress,targetHeight) = {
354354 let boostingContractAddress = valueOrErrorMessage(addressFromString(getStrOrFail(this, keyBoostingContract)), wrapErr("invalid boosting contract address"))
355355 $Tuple2(nil, {
356356 let @ = invoke(boostingContractAddress, "getUserGwxAmountAtHeightREADONLY", [userAddress, targetHeight], nil)
357357 if ($isInstanceOf(@, "Int"))
358358 then @
359359 else throw(($getType(@) + " couldn't be cast to Int"))
360360 })
361361 }
362362
363363
364364
365365 @Callable(i)
366366 func constructor (factoryContract,votingEmissionCandidateContract,boostingContract,stakingContract,epochLength) = {
367367 let checks = [mustManager(i), if ((addressFromString(factoryContract) != unit))
368368 then true
369369 else "invalid factory contract address", if ((addressFromString(votingEmissionCandidateContract) != unit))
370370 then true
371371 else "invalid voting emission candidate contract address", if ((addressFromString(boostingContract) != unit))
372372 then true
373373 else "invalid boosting contract address", if ((addressFromString(stakingContract) != unit))
374374 then true
375375 else "invalid staking contract address", if ((epochLength > 0))
376376 then true
377377 else throwErr("invalid epoch length")]
378378 if ((checks == checks))
379379 then $Tuple2([StringEntry(keyFactoryContract, factoryContract), StringEntry(keyVotingEmissionCandidateContract, votingEmissionCandidateContract), StringEntry(keyBoostingContract, boostingContract), StringEntry(keyStakingContract, stakingContract), IntegerEntry(keyEpochLength, epochLength)], unit)
380380 else throw("Strict value is not equal to itself.")
381381 }
382382
383383
384384
385385 @Callable(i)
386386 func create (amountAssetId,priceAssetId) = {
387387 let checks = [if ((toBase58String(i.caller.bytes) == valueOrElse(getString(this, keyVotingEmissionCandidateContract), "")))
388388 then true
389389 else mustManager(i)]
390390 if ((checks == checks))
391391 then {
392392 let pool = $Tuple2(amountAssetId, priceAssetId)
393393 let inListActions = ([BooleanEntry(keyInList(pool), true)] ++ insertNodeActions(poolsListName, poolToString(pool)))
394394 let currentEpochIsNotDefined = (getInteger(this, keyCurrentEpoch) == unit)
395395 let startHeightActions = if (currentEpochIsNotDefined)
396396 then {
397397 let epoch = 0
398398 [IntegerEntry(keyCurrentEpoch, epoch), IntegerEntry(keyStartHeightByEpoch(epoch), height), IntegerEntry(keyStartHeight, height), IntegerEntry(keyCurrentEpochUi, epoch), IntegerEntry(keyStartHeightUi, height)]
399399 }
400400 else nil
401401 $Tuple2((inListActions ++ startHeightActions), unit)
402402 }
403403 else throw("Strict value is not equal to itself.")
404404 }
405405
406406
407407
408408 @Callable(i)
409409 func vote (amountAssetId,priceAssetId,amount) = {
410410 let pool = $Tuple2(amountAssetId, priceAssetId)
411411 let epoch = valueOrElse(getInteger(this, keyCurrentEpoch), 0)
412412 let startHeight = getIntOrFail(this, keyStartHeightByEpoch(epoch))
413413 let epochLength = getIntOrFail(this, keyEpochLength)
414414 let endHeight = (startHeight + epochLength)
415415 let finalizationStageOrUnit = getInteger(this, keyFinalizationStage)
416416 let used = valueOrElse(getInteger(this, keyUsed(i.caller, epoch)), 0)
417417 let vote = valueOrElse(getInteger(this, keyVote(pool, i.caller, epoch)), 0)
418418 let poolResult = valueOrElse(getInteger(this, keyVotingResult(pool, epoch)), 0)
419419 let totalVotes = valueOrElse(getInteger(this, keyTotalVotes(epoch)), 0)
420420 let gwxAmountAtEndTotal = {
421421 let @ = invoke(this, "getUserGwxAmountAtHeight", [toBase58String(i.caller.bytes), endHeight], nil)
422422 if ($isInstanceOf(@, "Int"))
423423 then @
424424 else throw(($getType(@) + " couldn't be cast to Int"))
425425 }
426426 let available = (gwxAmountAtEndTotal - used)
427427 let newVote = (vote + amount)
428428 let wxEmission = checkWxEmissionPoolLabel(pool)
429429 let checks = [if ((getBoolean(keyInList(pool)) != unit))
430430 then true
431431 else throwErr("invalid assets"), if ((endHeight > height))
432432 then true
433433 else throwErr("invalid height"), if ((finalizationStageOrUnit == unit))
434434 then true
435435 else throwErr("finalization in progress"), if ((gwxAmountAtEndTotal > 0))
436436 then true
437437 else throwErr("you do not have gWX"), if (if ((amount > 0))
438438 then (available >= amount)
439439 else false)
440440 then true
441441 else throwErr("invalid amount"), if (wxEmission)
442442 then true
443443 else throwErr("pool hasn't WX_EMISSION label")]
444444 if ((checks == checks))
445445 then {
446446 let votesListName = getVotesListName(pool)
447447 let userAddressStr = toString(i.caller)
448448 let votesListActions = if (containsNode(votesListName, userAddressStr))
449449 then nil
450450 else insertNodeActions(votesListName, userAddressStr)
451451 $Tuple2(([IntegerEntry(keyUsed(i.caller, epoch), (used + amount)), IntegerEntry(keyVote(pool, i.caller, epoch), newVote), IntegerEntry(keyVotingResult(pool, epoch), (poolResult + amount)), IntegerEntry(keyTotalVotes(epoch), (totalVotes + amount))] ++ votesListActions), unit)
452452 }
453453 else throw("Strict value is not equal to itself.")
454454 }
455455
456456
457457
458458 @Callable(i)
459459 func cancelVote (amountAssetId,priceAssetId) = {
460460 let pool = $Tuple2(amountAssetId, priceAssetId)
461461 let epoch = valueOrElse(getInteger(this, keyCurrentEpoch), 0)
462462 let startHeight = getIntOrFail(this, keyStartHeightByEpoch(epoch))
463463 let epochLength = getIntOrFail(this, keyEpochLength)
464464 let endHeight = (startHeight + epochLength)
465465 let finalizationStageOrUnit = getInteger(this, keyFinalizationStage)
466466 let used = valueOrElse(getInteger(this, keyUsed(i.caller, epoch)), 0)
467467 let vote = valueOrElse(getInteger(this, keyVote(pool, i.caller, epoch)), 0)
468468 let poolResult = valueOrElse(getInteger(this, keyVotingResult(pool, epoch)), 0)
469469 let totalVotes = valueOrElse(getInteger(this, keyTotalVotes(epoch)), 0)
470470 let checks = [if ((getBoolean(keyInList(pool)) != unit))
471471 then true
472472 else throwErr("invalid assets"), if ((endHeight > height))
473473 then true
474474 else throwErr("invalid height"), if ((finalizationStageOrUnit == unit))
475475 then true
476476 else throwErr("finalization in progress"), if ((vote > 0))
477477 then true
478478 else throwErr("no vote")]
479479 if ((checks == checks))
480480 then {
481481 let votesListName = getVotesListName(pool)
482482 let userAddressStr = toString(i.caller)
483483 $Tuple2(([IntegerEntry(keyUsed(i.caller, epoch), max([(used - vote), 0])), DeleteEntry(keyVote(pool, i.caller, epoch)), IntegerEntry(keyVotingResult(pool, epoch), (poolResult - vote)), IntegerEntry(keyTotalVotes(epoch), (totalVotes - vote))] ++ deleteNodeActions(votesListName, userAddressStr)), unit)
484484 }
485485 else throw("Strict value is not equal to itself.")
486486 }
487487
488488
489489
490490 @Callable(i)
491491 func setEpochLength (newEpochLength) = {
492492 let checks = [mustManager(i), if ((newEpochLength > 0))
493493 then true
494494 else throwErr("invalid epoch length")]
495495 if ((checks == checks))
496496 then $Tuple2([IntegerEntry(keyEpochLengthNew, newEpochLength)], unit)
497497 else throw("Strict value is not equal to itself.")
498498 }
499499
500500
501501
502502 @Callable(i)
503503 func setMaxDepth (newMaxDepth) = {
504504 let checks = [mustManager(i), if ((newMaxDepth > 0))
505505 then true
506506 else throwErr("invalid max depth")]
507507 if ((checks == checks))
508508 then $Tuple2([IntegerEntry(keyMaxDepth, newMaxDepth)], unit)
509509 else throw("Strict value is not equal to itself.")
510510 }
511511
512512
513513
514514 @Callable(i)
515515 func processPoolBalanceINTERNAL (poolStr) = {
516516 let checkCaller = mustThis(i)
517517 if ((checkCaller == checkCaller))
518518 then {
519519 let epoch = getIntOrFail(this, keyCurrentEpoch)
520520 let epochPrevious = (epoch - 1)
521521 let pool = stringToPool(poolStr)
522522 let $t01702017060 = pool
523523 let amountAssetId = $t01702017060._1
524524 let priceAssetId = $t01702017060._2
525525 let lpAssetId = getLpAssetByPoolAssets(amountAssetId, priceAssetId)
526526 let balanceIsOkCurrent = {
527527 let @ = invoke(factoryContract, "checkBalance", [lpAssetId], nil)
528528 if ($isInstanceOf(@, "Boolean"))
529529 then @
530530 else throw(($getType(@) + " couldn't be cast to Boolean"))
531531 }
532532 let balanceIsOkPrevious = !(valueOrElse(getBoolean(this, keyInsufficientBalances(pool, (epochPrevious - 1))), false))
533533 let actions = if (!(balanceIsOkCurrent))
534534 then if (!(balanceIsOkPrevious))
535535 then {
536536 let deleteWxEmissionInv = invoke(factoryContract, "deleteWxEmissionPoolLabel", [amountAssetId, priceAssetId], nil)
537537 if ((deleteWxEmissionInv == deleteWxEmissionInv))
538538 then {
539539 let modifyWeightInv = invoke(factoryContract, "modifyWeight", [lpAssetId, 0], nil)
540540 if ((modifyWeightInv == modifyWeightInv))
541541 then {
542542 let poolAddress = valueOrErrorMessage(getPoolInfo(amountAssetId, priceAssetId), wrapErr("invalid assets"))._1
543543 let newStatus = 3
544544 let setPoolStatusInv = invoke(factoryContract, "managePool", [toString(poolAddress), newStatus], nil)
545545 if ((setPoolStatusInv == setPoolStatusInv))
546546 then {
547547 let listActions = ([DeleteEntry(keyInList(pool))] ++ deleteNodeActions(poolsListName, poolToString(pool)))
548548 ([IntegerEntry(keyPoolShare(pool, epochPrevious), 0)] ++ listActions)
549549 }
550550 else throw("Strict value is not equal to itself.")
551551 }
552552 else throw("Strict value is not equal to itself.")
553553 }
554554 else throw("Strict value is not equal to itself.")
555555 }
556556 else [BooleanEntry(keyInsufficientBalances(pool, epochPrevious), true)]
557557 else nil
558558 $Tuple2(actions, unit)
559559 }
560560 else throw("Strict value is not equal to itself.")
561561 }
562562
563563
564564
565565 @Callable(i)
566566 func processVoteINTERNAL (poolStr,userAddressStr) = {
567567 let checkCaller = mustThis(i)
568568 if ((checkCaller == checkCaller))
569569 then {
570570 let userAddress = valueOrErrorMessage(addressFromString(userAddressStr), wrapErr(("processVoteINTERNAL: invalid user address " + userAddressStr)))
571571 let epoch = getIntOrFail(this, keyCurrentEpoch)
572572 let epochPrevious = (epoch - 1)
573573 let epochLength = getIntOrFail(this, keyEpochLength)
574574 let startHeight = getIntOrFail(this, keyStartHeightByEpoch(epoch))
575575 let endHeight = (startHeight + epochLength)
576576 let startHeightPrevious = getIntOrFail(this, keyStartHeightByEpoch(epochPrevious))
577577 let epochLengthPrevious = getIntOrFail(this, keyEpochLengthByEpoch(epochPrevious))
578578 let endHeightPrevious = (startHeightPrevious + epochLengthPrevious)
579579 let checkTargetEpoch = if ((epochPrevious >= 0))
580580 then true
581581 else throwErr("processVoteINTERNAL: invalid previous epoch")
582582 if ((checkTargetEpoch == checkTargetEpoch))
583583 then {
584584 let pool = stringToPool(poolStr)
585585 let $t01941319453 = pool
586586 let amountAssetId = $t01941319453._1
587587 let priceAssetId = $t01941319453._2
588588 let gwxAmountAtEndTotal = {
589589 let @ = invoke(this, "getUserGwxAmountAtHeight", [userAddressStr, endHeight], nil)
590590 if ($isInstanceOf(@, "Int"))
591591 then @
592592 else throw(($getType(@) + " couldn't be cast to Int"))
593593 }
594594 let gwxAmountAtEndTotalPrevious = {
595595 let @ = invoke(this, "getUserGwxAmountAtHeight", [userAddressStr, endHeightPrevious], nil)
596596 if ($isInstanceOf(@, "Int"))
597597 then @
598598 else throw(($getType(@) + " couldn't be cast to Int"))
599599 }
600600 let totalVotes = valueOrElse(getInteger(keyTotalVotes(epoch)), 0)
601601 let votingResult = valueOrElse(getInteger(keyVotingResult(pool, epoch)), 0)
602602 let votePrevious = valueOrErrorMessage(getInteger(keyVote(pool, userAddress, epochPrevious)), wrapErr((((("processVoteINTERNAL " + poolStr) + " ") + userAddressStr) + ": no previous vote")))
603603 let used = valueOrElse(getInteger(this, keyUsed(userAddress, epoch)), 0)
604604 let lpAssetIdStr = getLpAssetByPoolAssets(amountAssetId, priceAssetId)
605605 let votingResultStakedPrevious = valueOrElse(getInteger(keyVotingResultStaked(lpAssetIdStr, epochPrevious)), 0)
606606 let stakingContract = addressFromStringValue(getStrOrFail(this, keyStakingContract))
607607 let stakedByUser = valueOrElse(getInteger(stakingContract, keyStakedByUser(lpAssetIdStr, userAddressStr)), 0)
608608 let votingResultStakedActions = if ((stakedByUser == 0))
609609 then nil
610610 else [IntegerEntry(keyVotingResultStaked(lpAssetIdStr, epochPrevious), (votingResultStakedPrevious + votePrevious))]
611611 let lpAssetId = getLpAssetByPoolAssets(amountAssetId, priceAssetId)
612612 let newVote = if ((gwxAmountAtEndTotalPrevious > 0))
613613 then fraction(votePrevious, gwxAmountAtEndTotal, gwxAmountAtEndTotalPrevious)
614614 else 0
615615 let actions = if ((newVote > 0))
616616 then [IntegerEntry(keyVote(pool, userAddress, epoch), newVote), IntegerEntry(keyTotalVotes(epoch), (totalVotes + newVote)), IntegerEntry(keyVotingResult(pool, epoch), (votingResult + newVote)), IntegerEntry(keyUsed(userAddress, epoch), (used + newVote))]
617617 else deleteNodeActions(getVotesListName(pool), userAddressStr)
618618 $Tuple2((actions ++ votingResultStakedActions), unit)
619619 }
620620 else throw("Strict value is not equal to itself.")
621621 }
622622 else throw("Strict value is not equal to itself.")
623623 }
624624
625625
626626
627627 @Callable(i)
628628 func processPoolINTERNAL (poolStr,force) = {
629629 let checkCaller = mustThis(i)
630630 if ((checkCaller == checkCaller))
631631 then {
632632 let targetEpoch = {
633633 let currentEpoch = getIntOrFail(this, keyCurrentEpoch)
634634 if (force)
635635 then currentEpoch
636636 else (currentEpoch - 1)
637637 }
638638 let checkTargetEpoch = if ((targetEpoch >= 0))
639639 then true
640640 else throwErr("processPoolINTERNAL: invalid target epoch")
641641 if ((checkTargetEpoch == checkTargetEpoch))
642642 then {
643643 let pool = stringToPool(poolStr)
644644 let $t02181621856 = pool
645645 let amountAssetId = $t02181621856._1
646646 let priceAssetId = $t02181621856._2
647647 let stakingContract = addressFromStringValue(getStrOrFail(this, keyStakingContract))
648648 let lpAssetId = getLpAssetByPoolAssets(amountAssetId, priceAssetId)
649649 let r = {
650650 let @ = invoke(stakingContract, "usersListTraversal", [lpAssetId], nil)
651651 if ($isInstanceOf(@, "Boolean"))
652652 then @
653653 else throw(($getType(@) + " couldn't be cast to Boolean"))
654654 }
655655 if ((r == r))
656656 then if (r)
657657 then $Tuple2(nil, true)
658658 else {
659659 let assetsStoreContract = addressFromStringValue(valueOrErrorMessage(getString(factoryContract, keyAssetsStoreContract), "invalid assets store contract"))
660660 let totalVotes = valueOrElse(getInteger(this, keyTotalVotes(targetEpoch)), 0)
661661 let votingResult = valueOrElse(getInteger(this, keyVotingResult(pool, targetEpoch)), 0)
662662 let share = if ((totalVotes == 0))
663663 then 0
664664 else fraction(votingResult, poolWeightMult, totalVotes)
665665 let modifyWeightInv = invoke(factoryContract, "modifyWeight", [lpAssetId, share], nil)
666666 if ((modifyWeightInv == modifyWeightInv))
667667 then $Tuple2([IntegerEntry(keyPoolShare(pool, targetEpoch), share)], false)
668668 else throw("Strict value is not equal to itself.")
669669 }
670670 else throw("Strict value is not equal to itself.")
671671 }
672672 else throw("Strict value is not equal to itself.")
673673 }
674674 else throw("Strict value is not equal to itself.")
675675 }
676676
677677
678678
679679 @Callable(i)
680680 func finalizeHelper () = {
681681 let force = valueOrElse(getBoolean(keyFinalizationShouldBeForced), false)
682682 let epoch = valueOrElse(getInteger(this, keyCurrentEpoch), 0)
683683 let previousEpoch = (epoch - 1)
684684 let startHeight = getIntOrFail(this, keyStartHeightByEpoch(epoch))
685685 let epochLength = getIntOrFail(this, keyEpochLength)
686686 let endHeight = (startHeight + epochLength)
687687 let finalizationStageOrUnit = getInteger(this, keyFinalizationStage)
688688 if (if (if ((height >= endHeight))
689689 then (finalizationStageOrUnit == unit)
690690 else false)
691691 then !(force)
692692 else false)
693693 then {
694694 let newEpoch = (epoch + 1)
695695 let newEpochLengthOption = getInteger(this, keyEpochLengthNew)
696696 let newEpochLengthActions = match newEpochLengthOption {
697697 case newEpochLength: Int =>
698698 [IntegerEntry(keyEpochLength, newEpochLength), DeleteEntry(keyEpochLengthNew)]
699699 case _: Unit =>
700700 nil
701701 case _ =>
702702 throw("Match error")
703703 }
704704 $Tuple2(([IntegerEntry(keyStartHeightByEpoch(newEpoch), height), IntegerEntry(keyStartHeight, height), IntegerEntry(keyCurrentEpoch, newEpoch), IntegerEntry(keyFinalizationStage, finalizationStageBalances), IntegerEntry(keyEpochLengthByEpoch(epoch), epochLength)] ++ newEpochLengthActions), true)
705705 }
706706 else if (if (force)
707707 then (finalizationStageOrUnit == unit)
708708 else false)
709709 then $Tuple2([IntegerEntry(keyFinalizationStage, finalizationStageShares)], true)
710710 else if ((finalizationStageOrUnit == unit))
711711 then $Tuple2(nil, false)
712712 else if ((finalizationStageOrUnit == finalizationStageBalances))
713713 then {
714714 let poolOrUnit = getString(keyNextPool)
715715 match poolOrUnit {
716716 case _: Unit =>
717717 match getString(keyListHead(poolsListName)) {
718718 case _: Unit =>
719719 $Tuple2([IntegerEntry(keyFinalizationStage, finalizationStageTotal), DeleteEntry(keyNextPool)], true)
720720 case nextPoolStr: String =>
721721 $Tuple2([StringEntry(keyNextPool, nextPoolStr)], true)
722722 case _ =>
723723 throw("Match error")
724724 }
725725 case poolStr: String =>
726726 let nextPoolOrUnit = getString(keyListNext(poolsListName, poolStr))
727727 if ((nextPoolOrUnit == nextPoolOrUnit))
728728 then {
729729 let r = invoke(this, "processPoolBalanceINTERNAL", [poolStr], nil)
730730 if ((r == r))
731731 then match nextPoolOrUnit {
732732 case _: Unit =>
733733 $Tuple2([IntegerEntry(keyFinalizationStage, finalizationStageTotal), DeleteEntry(keyNextPool)], true)
734734 case nextPoolStr: String =>
735735 $Tuple2([StringEntry(keyNextPool, nextPoolStr)], true)
736736 case _ =>
737737 throw("Match error")
738738 }
739739 else throw("Strict value is not equal to itself.")
740740 }
741741 else throw("Strict value is not equal to itself.")
742742 case _ =>
743743 throw("Match error")
744744 }
745745 }
746746 else if ((finalizationStageOrUnit == finalizationStageTotal))
747747 then {
748748 let poolOrUnit = getString(keyNextPool)
749749 let userOrUnit = getString(keyNextUser)
750750 match poolOrUnit {
751751 case _: Unit =>
752752 match getString(keyListHead(poolsListName)) {
753753 case _: Unit =>
754754 $Tuple2([IntegerEntry(keyFinalizationStage, finalizationStageShares), DeleteEntry(keyNextPool), DeleteEntry(keyNextUser)], true)
755755 case poolsHeadStr: String =>
756756 $Tuple2([StringEntry(keyNextPool, poolsHeadStr)], true)
757757 case _ =>
758758 throw("Match error")
759759 }
760760 case poolStr: String =>
761761 let pool = stringToPool(poolStr)
762762 let nextUserOrUnit = match userOrUnit {
763763 case _: Unit =>
764764 getString(keyListHead(getVotesListName(pool)))
765765 case user: String =>
766766 let next = getString(keyListNext(getVotesListName(pool), user))
767767 if ((next == next))
768768 then {
769769 let processVoteInv = invoke(this, "processVoteINTERNAL", [poolStr, user], nil)
770770 if ((processVoteInv == processVoteInv))
771771 then next
772772 else throw("Strict value is not equal to itself.")
773773 }
774774 else throw("Strict value is not equal to itself.")
775775 case _ =>
776776 throw("Match error")
777777 }
778778 match nextUserOrUnit {
779779 case _: Unit =>
780780 let nextPoolOrUnit = getString(keyListNext(poolsListName, poolStr))
781781 match nextPoolOrUnit {
782782 case _: Unit =>
783783 $Tuple2([IntegerEntry(keyFinalizationStage, finalizationStageShares), DeleteEntry(keyNextPool), DeleteEntry(keyNextUser)], true)
784784 case s: String =>
785785 $Tuple2([StringEntry(keyNextPool, s), DeleteEntry(keyNextUser)], true)
786786 case _ =>
787787 throw("Match error")
788788 }
789789 case nextUser: String =>
790790 $Tuple2([StringEntry(keyNextUser, nextUser)], true)
791791 case _ =>
792792 throw("Match error")
793793 }
794794 case _ =>
795795 throw("Match error")
796796 }
797797 }
798798 else if ((finalizationStageOrUnit == finalizationStageShares))
799799 then {
800800 let poolOrUnit = getString(keyNextPool)
801801 match poolOrUnit {
802802 case _: Unit =>
803803 match getString(keyListHead(poolsListName)) {
804804 case _: Unit =>
805805 let actions = if (force)
806806 then [DeleteEntry(keyFinalizationStage), DeleteEntry(keyFinalizationShouldBeForced)]
807807 else [DeleteEntry(keyFinalizationStage), BooleanEntry(keyFinalized(previousEpoch), true), IntegerEntry(keyCurrentEpochUi, epoch), IntegerEntry(keyStartHeightUi, startHeight)]
808808 let gwxRewardDepositInv = gwxRewardDeposit()
809809 if ((gwxRewardDepositInv == gwxRewardDepositInv))
810810 then $Tuple2(actions, true)
811811 else throw("Strict value is not equal to itself.")
812812 case nextPoolStr: String =>
813813 $Tuple2([StringEntry(keyNextPool, nextPoolStr)], true)
814814 case _ =>
815815 throw("Match error")
816816 }
817817 case poolStr: String =>
818818 let nextPoolOrUnit = getString(keyListNext(poolsListName, poolStr))
819819 if ((nextPoolOrUnit == nextPoolOrUnit))
820820 then {
821821 let r = {
822822 let @ = invoke(this, "processPoolINTERNAL", [poolStr, force], nil)
823823 if ($isInstanceOf(@, "Boolean"))
824824 then @
825825 else throw(($getType(@) + " couldn't be cast to Boolean"))
826826 }
827827 if ((r == r))
828828 then if (r)
829829 then $Tuple2(nil, true)
830830 else match nextPoolOrUnit {
831831 case _: Unit =>
832832 let actions = if (force)
833833 then [DeleteEntry(keyFinalizationStage), DeleteEntry(keyFinalizationShouldBeForced), DeleteEntry(keyNextPool)]
834834 else [DeleteEntry(keyFinalizationStage), BooleanEntry(keyFinalized(previousEpoch), true), IntegerEntry(keyCurrentEpochUi, epoch), IntegerEntry(keyStartHeightUi, startHeight), DeleteEntry(keyNextPool)]
835835 let gwxRewardDepositInv = gwxRewardDeposit()
836836 if ((gwxRewardDepositInv == gwxRewardDepositInv))
837837 then $Tuple2(actions, true)
838838 else throw("Strict value is not equal to itself.")
839839 case nextPoolStr: String =>
840840 $Tuple2([StringEntry(keyNextPool, nextPoolStr)], true)
841841 case _ =>
842842 throw("Match error")
843843 }
844844 else throw("Strict value is not equal to itself.")
845845 }
846846 else throw("Strict value is not equal to itself.")
847847 case _ =>
848848 throw("Match error")
849849 }
850850 }
851851 else throwErr("finalization is broken")
852852 }
853853
854854
855855
856856 @Callable(i)
857857 func finalizeWrapper (counter) = {
858858 let votingEmissionRateContract = addressFromStringValue(getStringValue(this, keyVotingEmissionRateContract))
859859 let result = {
860860 let @ = invoke(this, "finalizeHelper", nil, nil)
861861 if ($isInstanceOf(@, "Boolean"))
862862 then @
863863 else throw(($getType(@) + " couldn't be cast to Boolean"))
864864 }
865865 if ((result == result))
866866 then if (!(result))
867867 then if ((counter == 0))
868868 then throwErr("Current voting is not over yet")
869869 else {
870870 let inv = invoke(votingEmissionRateContract, "finalize", nil, nil)
871871 if ((inv == inv))
872872 then $Tuple2(nil, unit)
873873 else throw("Strict value is not equal to itself.")
874874 }
875875 else {
876876 let maxDepth = valueOrElse(getInteger(this, keyMaxDepth), maxDepthDefault)
877877 if ((maxDepth > counter))
878878 then {
879879 let inv = invoke(this, "finalizeWrapper", [(counter + 1)], nil)
880880 if ((inv == inv))
881881 then $Tuple2(nil, unit)
882882 else throw("Strict value is not equal to itself.")
883883 }
884884 else $Tuple2(nil, unit)
885885 }
886886 else throw("Strict value is not equal to itself.")
887887 }
888888
889889
890890
891891 @Callable(i)
892892 func finalize () = {
893893 let inv = invoke(this, "finalizeWrapper", [0], nil)
894894 if ((inv == inv))
895895 then $Tuple2(nil, unit)
896896 else throw("Strict value is not equal to itself.")
897897 }
898898
899899
900900
901901 @Callable(i)
902902 func containsNodeREADONLY (listName,id) = $Tuple2(nil, containsNode(listName, id))
903903
904904
905905
906906 @Callable(i)
907907 func insertNode (listName,id) = {
908908 let checkCaller = mustManager(i)
909909 if ((checkCaller == checkCaller))
910910 then $Tuple2(insertNodeActions(listName, id), unit)
911911 else throw("Strict value is not equal to itself.")
912912 }
913913
914914
915915
916916 @Callable(i)
917917 func deleteNode (listName,id) = {
918918 let checkCaller = mustManager(i)
919919 if ((checkCaller == checkCaller))
920920 then $Tuple2(deleteNodeActions(listName, id), unit)
921921 else throw("Strict value is not equal to itself.")
922922 }
923923
924924
925925
926926 @Callable(i)
927927 func isFinalizationInProgress () = {
928928 let finalizationStageOrUnit = getInteger(this, keyFinalizationStage)
929929 let finalizationInProgress = (finalizationStageOrUnit != unit)
930930 $Tuple2(nil, finalizationInProgress)
931931 }
932932
933933
934934
935935 @Callable(i)
936936 func deletePool (amountAssetId,priceAssetId) = {
937937 let checkCaller = if (if ((i.caller == factoryContract))
938938 then true
939939 else mustManager(i))
940940 then true
941941 else throwErr("Permission denied")
942942 if ((checkCaller == checkCaller))
943943 then {
944944 let listName = "pools"
945945 let pool = $Tuple2(amountAssetId, priceAssetId)
946946 let id = makeString([amountAssetId, priceAssetId], separator)
947947 let actions = if (containsNode(listName, id))
948948 then deleteNodeActions(listName, id)
949949 else nil
950950 ([DeleteEntry(keyInList(pool))] ++ actions)
951951 }
952952 else throw("Strict value is not equal to itself.")
953953 }
954954
955955
956956
957957 @Callable(i)
958958 func resume (amountAssetId,priceAssetId) = {
959959 let lpAssetId = getLpAssetByPoolAssets(amountAssetId, priceAssetId)
960960 let balanceIsOk = {
961961 let @ = invoke(factoryContract, "checkBalance", [lpAssetId], nil)
962962 if ($isInstanceOf(@, "Boolean"))
963963 then @
964964 else throw(($getType(@) + " couldn't be cast to Boolean"))
965965 }
966966 let payment = i.payments[0]
967967 let assetsStoreContract = addressFromStringValue(getStringValue(this, keyAssetsStoreContract))
968968 let kBoostingConfig = "%s__config"
969969 let idxCfgAssetId = 1
970970 let boostingContract = addressFromStringValue(getStrOrFail(this, keyBoostingContract))
971971 let wxAssetId = fromBase58String(split(getStringValue(boostingContract, kBoostingConfig), separator)[idxCfgAssetId])
972972 let amountAssetVerified = {
973973 let @ = invoke(assetsStoreContract, "isVerifiedREADONLY", [amountAssetId], nil)
974974 if ($isInstanceOf(@, "Boolean"))
975975 then @
976976 else throw(($getType(@) + " couldn't be cast to Boolean"))
977977 }
978978 let priceAssetVerified = {
979979 let @ = invoke(assetsStoreContract, "isVerifiedREADONLY", [priceAssetId], nil)
980980 if ($isInstanceOf(@, "Boolean"))
981981 then @
982982 else throw(($getType(@) + " couldn't be cast to Boolean"))
983983 }
984984 let resumptionFee = valueOrElse(getInteger(this, keyResumptionFee), resumptionFeeDefault)
985985 let checks = [if (balanceIsOk)
986986 then true
987987 else throwErr("insufficient balances"), if ((size(i.payments) == 1))
988988 then true
989989 else throwErr("1 payment is required"), if ((payment.assetId == wxAssetId))
990990 then true
991991 else throwErr("invalid payment asset id"), if ((payment.amount == resumptionFee))
992992 then true
993993 else throwErr("invalid payment amount"), if (if (amountAssetVerified)
994994 then priceAssetVerified
995995 else false)
996996 then true
997997 else throwErr("both assets should be verified")]
998998 if ((checks == checks))
999999 then {
1000- let pool = $Tuple2(amountAssetId, priceAssetId)
1001- let inListActions = ([BooleanEntry(keyInList(pool), true)] ++ insertNodeActions(poolsListName, poolToString(pool)))
1002- $Tuple2(inListActions, unit)
1000+ let setWxEmissionInv = invoke(factoryContract, "setWxEmissionPoolLabel", [amountAssetId, priceAssetId], nil)
1001+ if ((setWxEmissionInv == setWxEmissionInv))
1002+ then {
1003+ let pool = $Tuple2(amountAssetId, priceAssetId)
1004+ let inListActions = ([BooleanEntry(keyInList(pool), true)] ++ insertNodeActions(poolsListName, poolToString(pool)))
1005+ $Tuple2(inListActions, unit)
1006+ }
1007+ else throw("Strict value is not equal to itself.")
10031008 }
10041009 else throw("Strict value is not equal to itself.")
10051010 }
10061011
10071012
10081013 @Verifier(tx)
10091014 func verify () = {
10101015 let targetPublicKey = match managerPublicKeyOrUnit() {
10111016 case pk: ByteVector =>
10121017 pk
10131018 case _: Unit =>
10141019 tx.senderPublicKey
10151020 case _ =>
10161021 throw("Match error")
10171022 }
10181023 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
10191024 }
10201025

github/deemru/w8io/fabc49c 
81.37 ms