tx · GGrxUtyWStFqoWpfsizaH2df2wUuz1wdjQGdkBjksJVx 3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr: -0.02700000 Waves 2024.04.17 09:39 [3066422] smart account 3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr > SELF 0.00000000 Waves
{ "type": 13, "id": "GGrxUtyWStFqoWpfsizaH2df2wUuz1wdjQGdkBjksJVx", "fee": 2700000, "feeAssetId": null, "timestamp": 1713335985603, "version": 2, "chainId": 84, "sender": "3N9Zi6AcWcGbM23jQJ4fnzFsoHoTsxYDznr", "senderPublicKey": "GFbasS3jufhZkK4xR7tdTjjnP8K33KvJFEDHRtxXDkaJ", "proofs": [ "3g4rQKcH5hmFVTW3F7q6PXUFaBiBiCgKMaSQMA1JR9qW6ZJjHKdAJYNxThsrxgQrKVmBB4GcDjpGnoxtRJivPW6o" ], "script": "base64:BgKtGggCEgQKAggBEgcKBQgICAgBEgQKAggIEgUKAwgIARIECgIICBIDCgEBEgMKAQESAwoBCBIECgIICBIECgIIBBIAEgMKAQESABIECgIICBIECgIICBIECgIICBIAEgQKAggIEgQKAggIIglzZXBhcmF0b3IiDnBvb2xXZWlnaHRNdWx0Ig9tYXhEZXB0aERlZmF1bHQiGWZpbmFsaXphdGlvblN0YWdlQmFsYW5jZXMiFmZpbmFsaXphdGlvblN0YWdlVG90YWwiF2ZpbmFsaXphdGlvblN0YWdlU2hhcmVzIhRyZXN1bXB0aW9uRmVlRGVmYXVsdCIOa2V5RXBvY2hMZW5ndGgiEWtleUVwb2NoTGVuZ3RoTmV3IhVrZXlFcG9jaExlbmd0aEJ5RXBvY2giBWVwb2NoIg9rZXlDdXJyZW50RXBvY2giC2tleU1heERlcHRoIhBrZXlSZXN1bXB0aW9uRmVlIiJrZXlWb3RpbmdFbWlzc2lvbkNhbmRpZGF0ZUNvbnRyYWN0Ih1rZXlWb3RpbmdFbWlzc2lvblJhdGVDb250cmFjdCISa2V5RmFjdG9yeUNvbnRyYWN0I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QJjWg9zZW5kZXJQdWJsaWNLZXkJAAIBAgtNYXRjaCBlcnJvcgkA9AMDCAUCY1oJYm9keUJ5dGVzCQCRAwIIBQJjWgZwcm9vZnMAAAUCZGIAx6uQ", "height": 3066422, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: Gf6pwhR3UYk3PnoMQGNGJTH1ioev6wyS3FTEY5qj9AC3 Next: GSPTD42ZfJuujPW4kMVGFUbmJF82gZzGM2p1WJ26e4mc Diff:
Old | New | Differences | |
---|---|---|---|
11 | 11 | ||
12 | 12 | let e = 1 | |
13 | 13 | ||
14 | - | let f = | |
14 | + | let f = 2 | |
15 | 15 | ||
16 | - | let g = | |
16 | + | let g = 500000000000 | |
17 | 17 | ||
18 | - | func h (i) = makeString(["%s%d", "epochLength", toString(i)], a) | |
18 | + | let h = makeString(["%s", "epochLength"], a) | |
19 | + | ||
20 | + | let i = makeString(["%s%s", "epochLength__new"], a) | |
21 | + | ||
22 | + | func j (k) = makeString(["%s%d", "epochLength", toString(k)], a) | |
19 | 23 | ||
20 | 24 | ||
21 | - | let | |
25 | + | let l = makeString(["%s", "currentEpoch"], a) | |
22 | 26 | ||
23 | - | let | |
27 | + | let m = makeString(["%s", "maxDepth"], a) | |
24 | 28 | ||
25 | - | let | |
29 | + | let n = makeString(["%s", "resumptionFee"], a) | |
26 | 30 | ||
27 | - | let | |
31 | + | let o = makeString(["%s", "votingEmissionCandidateContract"], a) | |
28 | 32 | ||
29 | - | let | |
33 | + | let p = makeString(["%s", "votingEmissionRateContract"], a) | |
30 | 34 | ||
31 | - | let | |
35 | + | let q = makeString(["%s", "factoryContract"], a) | |
32 | 36 | ||
33 | - | let | |
37 | + | let r = makeString(["%s", "boostingContract"], a) | |
34 | 38 | ||
35 | - | let | |
39 | + | let s = makeString(["%s", "stakingContract"], a) | |
36 | 40 | ||
37 | - | let | |
41 | + | let t = makeString(["%s", "assetsStoreContract"], a) | |
38 | 42 | ||
39 | - | let | |
43 | + | let u = makeString(["%s", "finalizationStage"], a) | |
40 | 44 | ||
41 | - | let | |
45 | + | let v = makeString(["%s", "nextPool"], a) | |
42 | 46 | ||
43 | - | let | |
47 | + | let w = makeString(["%s", "nextUser"], a) | |
44 | 48 | ||
45 | - | let | |
49 | + | let x = makeString(["%s", "startHeight"], a) | |
46 | 50 | ||
47 | - | let | |
51 | + | let y = makeString(["%s", "currentEpochUi"], a) | |
48 | 52 | ||
49 | - | let | |
53 | + | let z = makeString(["%s", "startHeightUi"], a) | |
50 | 54 | ||
51 | - | func y (i) = makeString(["%s%d", "startHeight", toString(i)], a) | |
55 | + | let A = makeString(["%s", "force"], a) | |
56 | + | ||
57 | + | func B (k) = makeString(["%s%d", "startHeight", toString(k)], a) | |
52 | 58 | ||
53 | 59 | ||
54 | - | func | |
60 | + | func C (k) = makeString(["%s%d", "finalized", toString(k)], a) | |
55 | 61 | ||
56 | 62 | ||
57 | - | func | |
58 | - | let | |
59 | - | let | |
60 | - | let | |
61 | - | makeString(["%s%s%s", "inList", | |
63 | + | func D (E) = { | |
64 | + | let F = E | |
65 | + | let G = F._1 | |
66 | + | let H = F._2 | |
67 | + | makeString(["%s%s%s", "inList", G, H], a) | |
62 | 68 | } | |
63 | 69 | ||
64 | 70 | ||
65 | - | func F (G,i) = makeString(["%s%s%d", "used", toString(G), toString(i)], a) | |
66 | - | ||
67 | - | ||
68 | - | func H (B,G,i) = { | |
69 | - | let I = B | |
70 | - | let D = I._1 | |
71 | - | let E = I._2 | |
72 | - | makeString(["%s%s%s%s%d", "vote", D, E, toString(G), toString(i)], a) | |
71 | + | func I (E,k) = { | |
72 | + | let J = E | |
73 | + | let G = J._1 | |
74 | + | let H = J._2 | |
75 | + | makeString(["%s%s%s%d", "insufficientBalances", G, H, toString(k)], a) | |
73 | 76 | } | |
74 | 77 | ||
75 | 78 | ||
76 | - | func J (B,i) = { | |
77 | - | let K = B | |
78 | - | let D = K._1 | |
79 | - | let E = K._2 | |
80 | - | makeString(["%s%s%s%d", "votingResult", D, E, toString(i)], a) | |
79 | + | func K (L,k) = makeString(["%s%s%d", "used", toString(L), toString(k)], a) | |
80 | + | ||
81 | + | ||
82 | + | func M (E,L,k) = { | |
83 | + | let N = E | |
84 | + | let G = N._1 | |
85 | + | let H = N._2 | |
86 | + | makeString(["%s%s%s%s%d", "vote", G, H, toString(L), toString(k)], a) | |
81 | 87 | } | |
82 | 88 | ||
83 | 89 | ||
84 | - | func L (M,i) = makeString(["%s%s%d", "votingResultStaked", M, toString(i)], a) | |
85 | - | ||
86 | - | ||
87 | - | func N (B,i) = { | |
88 | - | let O = B | |
89 | - | let D = O._1 | |
90 | - | let E = O._2 | |
91 | - | makeString(["%s%s%s%d", "poolShare", D, E, toString(i)], a) | |
90 | + | func O (E,k) = { | |
91 | + | let P = E | |
92 | + | let G = P._1 | |
93 | + | let H = P._2 | |
94 | + | makeString(["%s%s%s%d", "votingResult", G, H, toString(k)], a) | |
92 | 95 | } | |
93 | 96 | ||
94 | 97 | ||
95 | - | func | |
98 | + | func Q (R,k) = makeString(["%s%s%d", "votingResultStaked", R, toString(k)], a) | |
96 | 99 | ||
97 | 100 | ||
98 | - | func Q (M,R) = makeString(["%s%s%s", "staked", R, M], a) | |
99 | - | ||
100 | - | ||
101 | - | func S (T) = makeString(["voting_emission.ride:", T], " ") | |
102 | - | ||
103 | - | ||
104 | - | func U (T) = throw(S(T)) | |
105 | - | ||
106 | - | ||
107 | - | func V (G,W,X) = { | |
108 | - | let Y = S(makeString(["mandatory ", toString(G), ".", W, " is not defined"], "")) | |
109 | - | valueOrErrorMessage({ | |
110 | - | let Z = X | |
111 | - | if ($isInstanceOf(Z, "String")) | |
112 | - | then { | |
113 | - | let aa = Z | |
114 | - | getString(G, W) | |
115 | - | } | |
116 | - | else if ($isInstanceOf(Z, "Int")) | |
117 | - | then { | |
118 | - | let ab = Z | |
119 | - | getInteger(G, W) | |
120 | - | } | |
121 | - | else U("invalid entry type") | |
122 | - | }, Y) | |
101 | + | func S (E,k) = { | |
102 | + | let T = E | |
103 | + | let G = T._1 | |
104 | + | let H = T._2 | |
105 | + | makeString(["%s%s%s%d", "poolShare", G, H, toString(k)], a) | |
123 | 106 | } | |
124 | 107 | ||
125 | 108 | ||
126 | - | func ac (G,W) = { | |
127 | - | let ad = V(G, W, "") | |
128 | - | if ($isInstanceOf(ad, "String")) | |
129 | - | then ad | |
130 | - | else throw(($getType(ad) + " couldn't be cast to String")) | |
109 | + | func U (k) = makeString(["%s%d", "totalVotes", toString(k)], a) | |
110 | + | ||
111 | + | ||
112 | + | func V (R,W) = makeString(["%s%s%s", "staked", W, R], a) | |
113 | + | ||
114 | + | ||
115 | + | func X (Y) = makeString(["voting_emission.ride:", Y], " ") | |
116 | + | ||
117 | + | ||
118 | + | func Z (Y) = throw(X(Y)) | |
119 | + | ||
120 | + | ||
121 | + | func aa (L,ab,ac) = { | |
122 | + | let ad = X(makeString(["mandatory ", toString(L), ".", ab, " is not defined"], "")) | |
123 | + | valueOrErrorMessage({ | |
124 | + | let ae = ac | |
125 | + | if ($isInstanceOf(ae, "String")) | |
126 | + | then { | |
127 | + | let af = ae | |
128 | + | getString(L, ab) | |
129 | + | } | |
130 | + | else if ($isInstanceOf(ae, "Int")) | |
131 | + | then { | |
132 | + | let ag = ae | |
133 | + | getInteger(L, ab) | |
134 | + | } | |
135 | + | else Z("invalid entry type") | |
136 | + | }, ad) | |
131 | 137 | } | |
132 | 138 | ||
133 | 139 | ||
134 | - | func | |
135 | - | let | |
136 | - | if ($isInstanceOf( | |
137 | - | then | |
138 | - | else throw(($getType( | |
140 | + | func ah (L,ab) = { | |
141 | + | let ai = aa(L, ab, "") | |
142 | + | if ($isInstanceOf(ai, "String")) | |
143 | + | then ai | |
144 | + | else throw(($getType(ai) + " couldn't be cast to String")) | |
139 | 145 | } | |
140 | 146 | ||
141 | 147 | ||
142 | - | func af (B) = ((B._1 + a) + B._2) | |
143 | - | ||
144 | - | ||
145 | - | func ag (aa) = { | |
146 | - | let ah = split(aa, a) | |
147 | - | if ((size(ah) == 2)) | |
148 | - | then $Tuple2(ah[0], ah[1]) | |
149 | - | else U("invalid pool string") | |
148 | + | func aj (L,ab) = { | |
149 | + | let ai = aa(L, ab, 0) | |
150 | + | if ($isInstanceOf(ai, "Int")) | |
151 | + | then ai | |
152 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
150 | 153 | } | |
151 | 154 | ||
152 | 155 | ||
153 | - | let ai = addressFromStringValue(ac(this, n)) | |
154 | - | ||
155 | - | let aj = 10 | |
156 | - | ||
157 | - | func ak () = "%s__factoryConfig" | |
156 | + | func ak (E) = ((E._1 + a) + E._2) | |
158 | 157 | ||
159 | 158 | ||
160 | - | func al (am) = split(ac(am, ak()), a) | |
161 | - | ||
162 | - | ||
163 | - | func an (ao) = addressFromStringValue(ao[aj]) | |
164 | - | ||
165 | - | ||
166 | - | func ap (D,E) = { | |
167 | - | func aq (ar) = ("%s%s%s__mappings__baseAsset2internalId__" + ar) | |
168 | - | ||
169 | - | func as (at,au) = (((("%d%d%s%s__" + toString(at)) + "__") + toString(au)) + "__mappings__poolAssets2PoolContract") | |
170 | - | ||
171 | - | func av (aw) = (("%s%s%s__" + aw) + "__mappings__poolContract2LpAsset") | |
172 | - | ||
173 | - | let ax = ae(ai, aq(D)) | |
174 | - | let ay = ae(ai, aq(E)) | |
175 | - | let aw = ac(ai, as(ax, ay)) | |
176 | - | let az = ac(ai, av(aw)) | |
177 | - | az | |
159 | + | func al (af) = { | |
160 | + | let am = split(af, a) | |
161 | + | if ((size(am) == 2)) | |
162 | + | then $Tuple2(am[0], am[1]) | |
163 | + | else Z("invalid pool string") | |
178 | 164 | } | |
179 | 165 | ||
180 | 166 | ||
181 | - | func aA (B) = { | |
182 | - | let aB = B | |
183 | - | let D = aB._1 | |
184 | - | let E = aB._2 | |
185 | - | let ad = invoke(ai, "checkWxEmissionPoolLabel", [D, E], nil) | |
186 | - | if ($isInstanceOf(ad, "Boolean")) | |
187 | - | then ad | |
188 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
167 | + | let an = addressFromStringValue(ah(this, q)) | |
168 | + | ||
169 | + | let ao = 10 | |
170 | + | ||
171 | + | func ap () = "%s__factoryConfig" | |
172 | + | ||
173 | + | ||
174 | + | func aq (ar) = split(ah(ar, ap()), a) | |
175 | + | ||
176 | + | ||
177 | + | func as (at) = addressFromStringValue(at[ao]) | |
178 | + | ||
179 | + | ||
180 | + | func au (G,H) = { | |
181 | + | let av = { | |
182 | + | let ai = invoke(an, "poolInfoREADONLY", [G, H], nil) | |
183 | + | if ($isInstanceOf(ai, "(Address, ByteVector)")) | |
184 | + | then ai | |
185 | + | else unit | |
186 | + | } | |
187 | + | av | |
189 | 188 | } | |
190 | 189 | ||
191 | 190 | ||
192 | - | func aC () = { | |
193 | - | let ao = al(ai) | |
194 | - | let aD = an(ao) | |
195 | - | invoke(aD, "deposit", nil, nil) | |
191 | + | func aw (G,H) = { | |
192 | + | func ax (ay) = ("%s%s%s__mappings__baseAsset2internalId__" + ay) | |
193 | + | ||
194 | + | func az (aA,aB) = (((("%d%d%s%s__" + toString(aA)) + "__") + toString(aB)) + "__mappings__poolAssets2PoolContract") | |
195 | + | ||
196 | + | func aC (aD) = (("%s%s%s__" + aD) + "__mappings__poolContract2LpAsset") | |
197 | + | ||
198 | + | let aE = aj(an, ax(G)) | |
199 | + | let aF = aj(an, ax(H)) | |
200 | + | let aD = ah(an, az(aE, aF)) | |
201 | + | let aG = ah(an, aC(aD)) | |
202 | + | aG | |
196 | 203 | } | |
197 | 204 | ||
198 | 205 | ||
199 | - | let aE = "pools" | |
200 | - | ||
201 | - | func aF (B) = { | |
202 | - | let aG = B | |
203 | - | let D = aG._1 | |
204 | - | let E = aG._2 | |
205 | - | makeString(["votes", D, E], a) | |
206 | + | func aH (E) = { | |
207 | + | let aI = E | |
208 | + | let G = aI._1 | |
209 | + | let H = aI._2 | |
210 | + | let ai = invoke(an, "checkWxEmissionPoolLabel", [G, H], nil) | |
211 | + | if ($isInstanceOf(ai, "Boolean")) | |
212 | + | then ai | |
213 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
206 | 214 | } | |
207 | 215 | ||
208 | 216 | ||
209 | - | func aH (aI) = { | |
210 | - | let aJ = if ((aI == aE)) | |
211 | - | then "%s%s" | |
212 | - | else "%s%s%s%s" | |
213 | - | makeString([aJ, aI, "head"], a) | |
217 | + | func aJ () = { | |
218 | + | let at = aq(an) | |
219 | + | let aK = as(at) | |
220 | + | invoke(aK, "deposit", nil, nil) | |
214 | 221 | } | |
215 | 222 | ||
216 | 223 | ||
217 | - | func aK (aI) = { | |
218 | - | let aJ = if ((aI == aE)) | |
219 | - | then "%s%s" | |
220 | - | else "%s%s%s%s" | |
221 | - | makeString([aJ, aI, "size"], a) | |
224 | + | let aL = "pools" | |
225 | + | ||
226 | + | func aM (E) = { | |
227 | + | let aN = E | |
228 | + | let G = aN._1 | |
229 | + | let H = aN._2 | |
230 | + | makeString(["votes", G, H], a) | |
222 | 231 | } | |
223 | 232 | ||
224 | 233 | ||
225 | - | func | |
226 | - | let | |
227 | - | then "%s%s | |
228 | - | else "%s%s%s%s | |
229 | - | makeString([ | |
234 | + | func aO (aP) = { | |
235 | + | let aQ = if ((aP == aL)) | |
236 | + | then "%s%s" | |
237 | + | else "%s%s%s%s" | |
238 | + | makeString([aQ, aP, "head"], a) | |
230 | 239 | } | |
231 | 240 | ||
232 | 241 | ||
233 | - | func | |
234 | - | let | |
235 | - | then "%s%s | |
236 | - | else "%s%s%s%s | |
237 | - | makeString([ | |
242 | + | func aR (aP) = { | |
243 | + | let aQ = if ((aP == aL)) | |
244 | + | then "%s%s" | |
245 | + | else "%s%s%s%s" | |
246 | + | makeString([aQ, aP, "size"], a) | |
238 | 247 | } | |
239 | 248 | ||
240 | 249 | ||
241 | - | func aO (aI,aM) = { | |
242 | - | let aP = getString(this, aH(aI)) | |
243 | - | let aQ = getString(this, aL(aI, aM)) | |
244 | - | let aR = getString(this, aN(aI, aM)) | |
245 | - | if (if ((aM == valueOrElse(aP, ""))) | |
246 | - | then true | |
247 | - | else (aQ != unit)) | |
248 | - | then true | |
249 | - | else (aR != unit) | |
250 | + | func aS (aP,aT) = { | |
251 | + | let aQ = if ((aP == aL)) | |
252 | + | then "%s%s%s%s" | |
253 | + | else "%s%s%s%s%s" | |
254 | + | makeString([aQ, aP, aT, "prev"], a) | |
250 | 255 | } | |
251 | 256 | ||
252 | 257 | ||
253 | - | func aS (aI,aM) = { | |
254 | - | let aP = getString(this, aH(aI)) | |
255 | - | let aT = valueOrElse(getInteger(this, aK(aI)), 0) | |
256 | - | let aU = if (!(aO(aI, aM))) | |
258 | + | func aU (aP,aT) = { | |
259 | + | let aQ = if ((aP == aL)) | |
260 | + | then "%s%s%s%s" | |
261 | + | else "%s%s%s%s%s" | |
262 | + | makeString([aQ, aP, aT, "next"], a) | |
263 | + | } | |
264 | + | ||
265 | + | ||
266 | + | func aV (aP,aT) = { | |
267 | + | let aW = getString(this, aO(aP)) | |
268 | + | let aX = getString(this, aS(aP, aT)) | |
269 | + | let aY = getString(this, aU(aP, aT)) | |
270 | + | if (if ((aT == valueOrElse(aW, ""))) | |
257 | 271 | then true | |
258 | - | else U("Node exists") | |
259 | - | if ((aU == aU)) | |
260 | - | then (([IntegerEntry(aK(aI), (aT + 1))] ++ (if ((aP != unit)) | |
261 | - | then [StringEntry(aN(aI, aM), value(aP)), StringEntry(aL(aI, value(aP)), aM)] | |
262 | - | else nil)) ++ [StringEntry(aH(aI), aM)]) | |
272 | + | else (aX != unit)) | |
273 | + | then true | |
274 | + | else (aY != unit) | |
275 | + | } | |
276 | + | ||
277 | + | ||
278 | + | func aZ (aP,aT) = { | |
279 | + | let aW = getString(this, aO(aP)) | |
280 | + | let ba = valueOrElse(getInteger(this, aR(aP)), 0) | |
281 | + | let bb = if (!(aV(aP, aT))) | |
282 | + | then true | |
283 | + | else Z("Node exists") | |
284 | + | if ((bb == bb)) | |
285 | + | then (([IntegerEntry(aR(aP), (ba + 1))] ++ (if ((aW != unit)) | |
286 | + | then [StringEntry(aU(aP, aT), value(aW)), StringEntry(aS(aP, value(aW)), aT)] | |
287 | + | else nil)) ++ [StringEntry(aO(aP), aT)]) | |
263 | 288 | else throw("Strict value is not equal to itself.") | |
264 | 289 | } | |
265 | 290 | ||
266 | 291 | ||
267 | - | func | |
268 | - | let | |
269 | - | let | |
270 | - | let | |
271 | - | let | |
272 | - | ([IntegerEntry( | |
273 | - | then ( | |
292 | + | func bc (aP,aT) = { | |
293 | + | let aW = getString(this, aO(aP)) | |
294 | + | let ba = valueOrElse(getInteger(this, aR(aP)), 0) | |
295 | + | let aX = getString(this, aS(aP, aT)) | |
296 | + | let aY = getString(this, aU(aP, aT)) | |
297 | + | ([IntegerEntry(aR(aP), (ba - 1))] ++ (if (if ((aX != unit)) | |
298 | + | then (aY != unit) | |
274 | 299 | else false) | |
275 | - | then [StringEntry( | |
276 | - | else if (( | |
277 | - | then [StringEntry( | |
278 | - | else if (( | |
279 | - | then [DeleteEntry( | |
280 | - | else if (( | |
281 | - | then [DeleteEntry( | |
282 | - | else | |
300 | + | then [StringEntry(aU(aP, value(aX)), value(aY)), StringEntry(aS(aP, value(aY)), value(aX)), DeleteEntry(aS(aP, aT)), DeleteEntry(aU(aP, aT))] | |
301 | + | else if ((aY != unit)) | |
302 | + | then [StringEntry(aO(aP), value(aY)), DeleteEntry(aU(aP, aT)), DeleteEntry(aS(aP, value(aY)))] | |
303 | + | else if ((aX != unit)) | |
304 | + | then [DeleteEntry(aS(aP, aT)), DeleteEntry(aU(aP, value(aX)))] | |
305 | + | else if ((aT == valueOrElse(aW, ""))) | |
306 | + | then [DeleteEntry(aO(aP))] | |
307 | + | else Z(((("invalid node: " + aP) + ".") + aT)))) | |
283 | 308 | } | |
284 | 309 | ||
285 | 310 | ||
286 | - | func | |
311 | + | func bd () = "%s__managerVaultAddress" | |
287 | 312 | ||
288 | 313 | ||
289 | - | func | |
314 | + | func be () = "%s__managerPublicKey" | |
290 | 315 | ||
291 | 316 | ||
292 | - | func | |
293 | - | let | |
294 | - | if ($isInstanceOf( | |
317 | + | func bf () = { | |
318 | + | let ae = getString(bd()) | |
319 | + | if ($isInstanceOf(ae, "String")) | |
295 | 320 | then { | |
296 | - | let | |
297 | - | addressFromStringValue( | |
321 | + | let bg = ae | |
322 | + | addressFromStringValue(bg) | |
298 | 323 | } | |
299 | 324 | else this | |
300 | 325 | } | |
301 | 326 | ||
302 | 327 | ||
303 | - | func | |
304 | - | let | |
305 | - | let | |
306 | - | if ($isInstanceOf( | |
328 | + | func bh () = { | |
329 | + | let bi = bf() | |
330 | + | let ae = getString(bi, be()) | |
331 | + | if ($isInstanceOf(ae, "String")) | |
307 | 332 | then { | |
308 | - | let | |
309 | - | fromBase58String( | |
333 | + | let bg = ae | |
334 | + | fromBase58String(bg) | |
310 | 335 | } | |
311 | - | else if ($isInstanceOf( | |
336 | + | else if ($isInstanceOf(ae, "Unit")) | |
312 | 337 | then unit | |
313 | 338 | else throw("Match error") | |
314 | 339 | } | |
315 | 340 | ||
316 | 341 | ||
317 | - | func | |
318 | - | let | |
319 | - | if ($isInstanceOf( | |
342 | + | func bj (bk) = { | |
343 | + | let ae = bh() | |
344 | + | if ($isInstanceOf(ae, "ByteVector")) | |
320 | 345 | then { | |
321 | - | let | |
322 | - | ( | |
346 | + | let bl = ae | |
347 | + | (bk.callerPublicKey == bl) | |
323 | 348 | } | |
324 | - | else if ($isInstanceOf( | |
325 | - | then ( | |
349 | + | else if ($isInstanceOf(ae, "Unit")) | |
350 | + | then (bk.caller == this) | |
326 | 351 | else throw("Match error") | |
327 | 352 | } | |
328 | 353 | ||
329 | 354 | ||
330 | - | func | |
355 | + | func bm (bk) = if (bj(bk)) | |
331 | 356 | then true | |
332 | 357 | else throw("permission denied") | |
333 | 358 | ||
334 | 359 | ||
335 | - | func | |
360 | + | func bn (bk) = if ((bk.caller == this)) | |
336 | 361 | then true | |
337 | 362 | else throw("permission denied") | |
338 | 363 | ||
339 | 364 | ||
340 | - | @Callable( | |
341 | - | func getUserGwxAmountAtHeight ( | |
342 | - | let | |
365 | + | @Callable(bk) | |
366 | + | func getUserGwxAmountAtHeight (bo,bp) = { | |
367 | + | let bq = valueOrErrorMessage(addressFromString(ah(this, r)), X("invalid boosting contract address")) | |
343 | 368 | $Tuple2(nil, { | |
344 | - | let | |
345 | - | if ($isInstanceOf( | |
346 | - | then | |
347 | - | else throw(($getType( | |
369 | + | let ai = invoke(bq, "getUserGwxAmountAtHeightREADONLY", [bo, bp], nil) | |
370 | + | if ($isInstanceOf(ai, "Int")) | |
371 | + | then ai | |
372 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
348 | 373 | }) | |
349 | 374 | } | |
350 | 375 | ||
351 | 376 | ||
352 | 377 | ||
353 | - | @Callable( | |
354 | - | func constructor ( | |
355 | - | let | |
378 | + | @Callable(bk) | |
379 | + | func constructor (an,br,bs,bt,bu) = { | |
380 | + | let bv = [bm(bk), if ((addressFromString(an) != unit)) | |
356 | 381 | then true | |
357 | - | else "invalid factory contract address", if ((addressFromString( | |
382 | + | else "invalid factory contract address", if ((addressFromString(br) != unit)) | |
358 | 383 | then true | |
359 | - | else "invalid voting emission candidate contract address", if ((addressFromString( | |
384 | + | else "invalid voting emission candidate contract address", if ((addressFromString(bs) != unit)) | |
360 | 385 | then true | |
361 | - | else "invalid boosting contract address", if ((addressFromString( | |
386 | + | else "invalid boosting contract address", if ((addressFromString(bt) != unit)) | |
362 | 387 | then true | |
363 | - | else "invalid staking contract address", if (( | |
388 | + | else "invalid staking contract address", if ((bu > 0)) | |
364 | 389 | then true | |
365 | - | else | |
366 | - | if (( | |
367 | - | then $Tuple2([StringEntry( | |
390 | + | else Z("invalid epoch length")] | |
391 | + | if ((bv == bv)) | |
392 | + | then $Tuple2([StringEntry(q, an), StringEntry(o, br), StringEntry(r, bs), StringEntry(s, bt), IntegerEntry(h, bu)], unit) | |
368 | 393 | else throw("Strict value is not equal to itself.") | |
369 | 394 | } | |
370 | 395 | ||
371 | 396 | ||
372 | 397 | ||
373 | - | @Callable( | |
374 | - | func create ( | |
375 | - | let | |
398 | + | @Callable(bk) | |
399 | + | func create (G,H) = { | |
400 | + | let bv = [if ((toBase58String(bk.caller.bytes) == valueOrElse(getString(this, o), ""))) | |
376 | 401 | then true | |
377 | - | else | |
378 | - | if (( | |
402 | + | else bm(bk)] | |
403 | + | if ((bv == bv)) | |
379 | 404 | then { | |
380 | - | let | |
381 | - | let | |
382 | - | let | |
383 | - | let | |
405 | + | let E = $Tuple2(G, H) | |
406 | + | let bw = ([BooleanEntry(D(E), true)] ++ aZ(aL, ak(E))) | |
407 | + | let bx = (getInteger(this, l) == unit) | |
408 | + | let by = if (bx) | |
384 | 409 | then { | |
385 | - | let | |
386 | - | [IntegerEntry( | |
410 | + | let k = 0 | |
411 | + | [IntegerEntry(l, k), IntegerEntry(B(k), height), IntegerEntry(x, height), IntegerEntry(y, k), IntegerEntry(z, height)] | |
387 | 412 | } | |
388 | 413 | else nil | |
389 | - | $Tuple2(( | |
414 | + | $Tuple2((bw ++ by), unit) | |
390 | 415 | } | |
391 | 416 | else throw("Strict value is not equal to itself.") | |
392 | 417 | } | |
393 | 418 | ||
394 | 419 | ||
395 | 420 | ||
396 | - | @Callable( | |
397 | - | func vote ( | |
398 | - | let | |
399 | - | let | |
400 | - | let | |
401 | - | let | |
402 | - | let | |
403 | - | let | |
404 | - | let | |
405 | - | let | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | if ($isInstanceOf( | |
411 | - | then | |
412 | - | else throw(($getType( | |
421 | + | @Callable(bk) | |
422 | + | func vote (G,H,bz) = { | |
423 | + | let E = $Tuple2(G, H) | |
424 | + | let k = valueOrElse(getInteger(this, l), 0) | |
425 | + | let bA = aj(this, B(k)) | |
426 | + | let bu = aj(this, h) | |
427 | + | let bB = (bA + bu) | |
428 | + | let bC = getInteger(this, u) | |
429 | + | let bD = valueOrElse(getInteger(this, K(bk.caller, k)), 0) | |
430 | + | let bE = valueOrElse(getInteger(this, M(E, bk.caller, k)), 0) | |
431 | + | let bF = valueOrElse(getInteger(this, O(E, k)), 0) | |
432 | + | let bG = valueOrElse(getInteger(this, U(k)), 0) | |
433 | + | let bH = { | |
434 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [toBase58String(bk.caller.bytes), bB], nil) | |
435 | + | if ($isInstanceOf(ai, "Int")) | |
436 | + | then ai | |
437 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
413 | 438 | } | |
414 | - | let | |
415 | - | let | |
416 | - | let | |
417 | - | let | |
439 | + | let bI = (bH - bD) | |
440 | + | let bJ = (bE + bz) | |
441 | + | let bK = aH(E) | |
442 | + | let bv = [if ((getBoolean(D(E)) != unit)) | |
418 | 443 | then true | |
419 | - | else | |
444 | + | else Z("invalid assets"), if ((bB > height)) | |
420 | 445 | then true | |
421 | - | else | |
446 | + | else Z("invalid height"), if ((bC == unit)) | |
422 | 447 | then true | |
423 | - | else | |
448 | + | else Z("finalization in progress"), if ((bH > 0)) | |
424 | 449 | then true | |
425 | - | else | |
426 | - | then ( | |
450 | + | else Z("you do not have gWX"), if (if ((bz > 0)) | |
451 | + | then (bI >= bz) | |
427 | 452 | else false) | |
428 | 453 | then true | |
429 | - | else | |
454 | + | else Z("invalid amount"), if (bK) | |
430 | 455 | then true | |
431 | - | else | |
432 | - | if (( | |
456 | + | else Z("pool hasn't WX_EMISSION label")] | |
457 | + | if ((bv == bv)) | |
433 | 458 | then { | |
434 | - | let | |
435 | - | let | |
436 | - | let | |
459 | + | let bL = aM(E) | |
460 | + | let W = toString(bk.caller) | |
461 | + | let bM = if (aV(bL, W)) | |
437 | 462 | then nil | |
438 | - | else | |
439 | - | $Tuple2(([IntegerEntry( | |
463 | + | else aZ(bL, W) | |
464 | + | $Tuple2(([IntegerEntry(K(bk.caller, k), (bD + bz)), IntegerEntry(M(E, bk.caller, k), bJ), IntegerEntry(O(E, k), (bF + bz)), IntegerEntry(U(k), (bG + bz))] ++ bM), unit) | |
440 | 465 | } | |
441 | 466 | else throw("Strict value is not equal to itself.") | |
442 | 467 | } | |
443 | 468 | ||
444 | 469 | ||
445 | 470 | ||
446 | - | @Callable( | |
447 | - | func cancelVote ( | |
448 | - | let | |
449 | - | let | |
450 | - | let | |
451 | - | let | |
452 | - | let | |
453 | - | let | |
454 | - | let | |
455 | - | let | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
471 | + | @Callable(bk) | |
472 | + | func cancelVote (G,H) = { | |
473 | + | let E = $Tuple2(G, H) | |
474 | + | let k = valueOrElse(getInteger(this, l), 0) | |
475 | + | let bA = aj(this, B(k)) | |
476 | + | let bu = aj(this, h) | |
477 | + | let bB = (bA + bu) | |
478 | + | let bC = getInteger(this, u) | |
479 | + | let bD = valueOrElse(getInteger(this, K(bk.caller, k)), 0) | |
480 | + | let bE = valueOrElse(getInteger(this, M(E, bk.caller, k)), 0) | |
481 | + | let bF = valueOrElse(getInteger(this, O(E, k)), 0) | |
482 | + | let bG = valueOrElse(getInteger(this, U(k)), 0) | |
483 | + | let bv = [if ((getBoolean(D(E)) != unit)) | |
459 | 484 | then true | |
460 | - | else | |
485 | + | else Z("invalid assets"), if ((bB > height)) | |
461 | 486 | then true | |
462 | - | else | |
487 | + | else Z("invalid height"), if ((bC == unit)) | |
463 | 488 | then true | |
464 | - | else | |
489 | + | else Z("finalization in progress"), if ((bE > 0)) | |
465 | 490 | then true | |
466 | - | else | |
467 | - | if (( | |
491 | + | else Z("no vote")] | |
492 | + | if ((bv == bv)) | |
468 | 493 | then { | |
469 | - | let | |
470 | - | let | |
471 | - | $Tuple2(([IntegerEntry( | |
494 | + | let bL = aM(E) | |
495 | + | let W = toString(bk.caller) | |
496 | + | $Tuple2(([IntegerEntry(K(bk.caller, k), max([(bD - bE), 0])), DeleteEntry(M(E, bk.caller, k)), IntegerEntry(O(E, k), (bF - bE)), IntegerEntry(U(k), (bG - bE))] ++ bc(bL, W)), unit) | |
472 | 497 | } | |
473 | 498 | else throw("Strict value is not equal to itself.") | |
474 | 499 | } | |
475 | 500 | ||
476 | 501 | ||
477 | 502 | ||
478 | - | @Callable( | |
479 | - | func setEpochLength ( | |
480 | - | let | |
503 | + | @Callable(bk) | |
504 | + | func setEpochLength (bN) = { | |
505 | + | let bv = [bm(bk), if ((bN > 0)) | |
481 | 506 | then true | |
482 | - | else | |
483 | - | if (( | |
484 | - | then $Tuple2([IntegerEntry( | |
507 | + | else Z("invalid epoch length")] | |
508 | + | if ((bv == bv)) | |
509 | + | then $Tuple2([IntegerEntry(i, bN)], unit) | |
485 | 510 | else throw("Strict value is not equal to itself.") | |
486 | 511 | } | |
487 | 512 | ||
488 | 513 | ||
489 | 514 | ||
490 | - | @Callable( | |
491 | - | func setMaxDepth ( | |
492 | - | let | |
515 | + | @Callable(bk) | |
516 | + | func setMaxDepth (bO) = { | |
517 | + | let bv = [bm(bk), if ((bO > 0)) | |
493 | 518 | then true | |
494 | - | else | |
495 | - | if (( | |
496 | - | then $Tuple2([IntegerEntry( | |
519 | + | else Z("invalid max depth")] | |
520 | + | if ((bv == bv)) | |
521 | + | then $Tuple2([IntegerEntry(m, bO)], unit) | |
497 | 522 | else throw("Strict value is not equal to itself.") | |
498 | 523 | } | |
499 | 524 | ||
500 | 525 | ||
501 | 526 | ||
502 | - | @Callable( | |
503 | - | func | |
504 | - | let | |
505 | - | if (( | |
527 | + | @Callable(bk) | |
528 | + | func processPoolBalanceINTERNAL (bP) = { | |
529 | + | let bQ = bn(bk) | |
530 | + | if ((bQ == bQ)) | |
506 | 531 | then { | |
507 | - | let bh = valueOrErrorMessage(addressFromString(R), S(("processVoteINTERNAL: invalid user address " + R))) | |
508 | - | let i = ae(this, j) | |
509 | - | let bK = (i - 1) | |
510 | - | let bn = ae(this, f) | |
511 | - | let bt = ae(this, y(i)) | |
512 | - | let bu = (bt + bn) | |
513 | - | let bL = ae(this, y(bK)) | |
514 | - | let bM = ae(this, h(bK)) | |
515 | - | let bN = (bL + bM) | |
516 | - | let bO = if ((bK >= 0)) | |
532 | + | let k = aj(this, l) | |
533 | + | let bR = (k - 1) | |
534 | + | let E = al(bP) | |
535 | + | let bS = E | |
536 | + | let G = bS._1 | |
537 | + | let H = bS._2 | |
538 | + | let aG = aw(G, H) | |
539 | + | let bT = { | |
540 | + | let ai = invoke(an, "checkBalance", [aG], nil) | |
541 | + | if ($isInstanceOf(ai, "Boolean")) | |
542 | + | then ai | |
543 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
544 | + | } | |
545 | + | let bU = !(valueOrElse(getBoolean(this, I(E, (bR - 1))), false)) | |
546 | + | let bV = if (!(bT)) | |
547 | + | then if (!(bU)) | |
548 | + | then { | |
549 | + | let bW = invoke(an, "deleteWxEmissionPoolLabel", [G, H], nil) | |
550 | + | if ((bW == bW)) | |
551 | + | then { | |
552 | + | let bX = invoke(an, "modifyWeight", [aG, 0], nil) | |
553 | + | if ((bX == bX)) | |
554 | + | then { | |
555 | + | let bY = valueOrErrorMessage(au(G, H), X("invalid assets"))._1 | |
556 | + | let bZ = 3 | |
557 | + | let ca = invoke(an, "managePool", [toString(bY), bZ], nil) | |
558 | + | if ((ca == ca)) | |
559 | + | then { | |
560 | + | let cb = ([DeleteEntry(D(E))] ++ bc(aL, ak(E))) | |
561 | + | ([IntegerEntry(S(E, bR), 0)] ++ cb) | |
562 | + | } | |
563 | + | else throw("Strict value is not equal to itself.") | |
564 | + | } | |
565 | + | else throw("Strict value is not equal to itself.") | |
566 | + | } | |
567 | + | else throw("Strict value is not equal to itself.") | |
568 | + | } | |
569 | + | else [BooleanEntry(I(E, bR), true)] | |
570 | + | else nil | |
571 | + | $Tuple2(bV, unit) | |
572 | + | } | |
573 | + | else throw("Strict value is not equal to itself.") | |
574 | + | } | |
575 | + | ||
576 | + | ||
577 | + | ||
578 | + | @Callable(bk) | |
579 | + | func processVoteINTERNAL (bP,W) = { | |
580 | + | let bQ = bn(bk) | |
581 | + | if ((bQ == bQ)) | |
582 | + | then { | |
583 | + | let bo = valueOrErrorMessage(addressFromString(W), X(("processVoteINTERNAL: invalid user address " + W))) | |
584 | + | let k = aj(this, l) | |
585 | + | let bR = (k - 1) | |
586 | + | let bu = aj(this, h) | |
587 | + | let bA = aj(this, B(k)) | |
588 | + | let bB = (bA + bu) | |
589 | + | let cc = aj(this, B(bR)) | |
590 | + | let cd = aj(this, j(bR)) | |
591 | + | let ce = (cc + cd) | |
592 | + | let cf = if ((bR >= 0)) | |
517 | 593 | then true | |
518 | - | else | |
519 | - | if (( | |
594 | + | else Z("processVoteINTERNAL: invalid previous epoch") | |
595 | + | if ((cf == cf)) | |
520 | 596 | then { | |
521 | - | let B = ag(bI) | |
522 | - | let bP = B | |
523 | - | let D = bP._1 | |
524 | - | let E = bP._2 | |
525 | - | let bD = aA(B) | |
526 | - | let bA = { | |
527 | - | let ad = invoke(this, "getUserGwxAmountAtHeight", [R, bu], nil) | |
528 | - | if ($isInstanceOf(ad, "Int")) | |
529 | - | then ad | |
530 | - | else throw(($getType(ad) + " couldn't be cast to Int")) | |
597 | + | let E = al(bP) | |
598 | + | let cg = E | |
599 | + | let G = cg._1 | |
600 | + | let H = cg._2 | |
601 | + | let bH = { | |
602 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [W, bB], nil) | |
603 | + | if ($isInstanceOf(ai, "Int")) | |
604 | + | then ai | |
605 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
531 | 606 | } | |
532 | - | let | |
533 | - | let | |
534 | - | if ($isInstanceOf( | |
535 | - | then | |
536 | - | else throw(($getType( | |
607 | + | let ch = { | |
608 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [W, ce], nil) | |
609 | + | if ($isInstanceOf(ai, "Int")) | |
610 | + | then ai | |
611 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
537 | 612 | } | |
538 | - | let | |
539 | - | let | |
540 | - | let | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
544 | - | let | |
545 | - | let | |
546 | - | let | |
613 | + | let bG = valueOrElse(getInteger(U(k)), 0) | |
614 | + | let ci = valueOrElse(getInteger(O(E, k)), 0) | |
615 | + | let cj = valueOrErrorMessage(getInteger(M(E, bo, bR)), X((((("processVoteINTERNAL " + bP) + " ") + W) + ": no previous vote"))) | |
616 | + | let bD = valueOrElse(getInteger(this, K(bo, k)), 0) | |
617 | + | let R = aw(G, H) | |
618 | + | let ck = valueOrElse(getInteger(Q(R, bR)), 0) | |
619 | + | let bt = addressFromStringValue(ah(this, s)) | |
620 | + | let cl = valueOrElse(getInteger(bt, V(R, W)), 0) | |
621 | + | let cm = if ((cl == 0)) | |
547 | 622 | then nil | |
548 | - | else [IntegerEntry(L(M, bK), (bT + bS))] | |
549 | - | let az = ap(D, E) | |
550 | - | let bW = { | |
551 | - | let ad = invoke(ai, "checkBalance", [az], nil) | |
552 | - | if ($isInstanceOf(ad, "Boolean")) | |
553 | - | then ad | |
554 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
555 | - | } | |
556 | - | let bC = if ((bQ > 0)) | |
557 | - | then fraction(bS, bA, bQ) | |
623 | + | else [IntegerEntry(Q(R, bR), (ck + cj))] | |
624 | + | let aG = aw(G, H) | |
625 | + | let bJ = if ((ch > 0)) | |
626 | + | then fraction(cj, bH, ch) | |
558 | 627 | else 0 | |
559 | - | let bX = if (if (if ((bC > 0)) | |
560 | - | then bD | |
561 | - | else false) | |
562 | - | then bW | |
563 | - | else false) | |
564 | - | then [IntegerEntry(H(B, bh, i), bC), IntegerEntry(P(i), (bz + bC)), IntegerEntry(J(B, i), (bR + bC)), IntegerEntry(F(bh, i), (bw + bC))] | |
565 | - | else aV(aF(B), R) | |
566 | - | $Tuple2((bX ++ bV), unit) | |
628 | + | let bV = if ((bJ > 0)) | |
629 | + | then [IntegerEntry(M(E, bo, k), bJ), IntegerEntry(U(k), (bG + bJ)), IntegerEntry(O(E, k), (ci + bJ)), IntegerEntry(K(bo, k), (bD + bJ))] | |
630 | + | else bc(aM(E), W) | |
631 | + | $Tuple2((bV ++ cm), unit) | |
567 | 632 | } | |
568 | 633 | else throw("Strict value is not equal to itself.") | |
569 | 634 | } | |
572 | 637 | ||
573 | 638 | ||
574 | 639 | ||
575 | - | @Callable( | |
576 | - | func processPoolINTERNAL ( | |
577 | - | let | |
578 | - | if (( | |
640 | + | @Callable(bk) | |
641 | + | func processPoolINTERNAL (bP,cn) = { | |
642 | + | let bQ = bn(bk) | |
643 | + | if ((bQ == bQ)) | |
579 | 644 | then { | |
580 | - | let | |
581 | - | let | |
582 | - | if ( | |
583 | - | then | |
584 | - | else ( | |
645 | + | let co = { | |
646 | + | let cp = aj(this, l) | |
647 | + | if (cn) | |
648 | + | then cp | |
649 | + | else (cp - 1) | |
585 | 650 | } | |
586 | - | let | |
651 | + | let cf = if ((co >= 0)) | |
587 | 652 | then true | |
588 | - | else | |
589 | - | if (( | |
653 | + | else Z("processPoolINTERNAL: invalid target epoch") | |
654 | + | if ((cf == cf)) | |
590 | 655 | then { | |
591 | - | let | |
592 | - | let | |
593 | - | let | |
594 | - | let | |
595 | - | let | |
596 | - | let | |
597 | - | let | |
598 | - | let | |
599 | - | if ($isInstanceOf( | |
600 | - | then | |
601 | - | else throw(($getType( | |
656 | + | let E = al(bP) | |
657 | + | let cq = E | |
658 | + | let G = cq._1 | |
659 | + | let H = cq._2 | |
660 | + | let bt = addressFromStringValue(ah(this, s)) | |
661 | + | let aG = aw(G, H) | |
662 | + | let cr = { | |
663 | + | let ai = invoke(bt, "usersListTraversal", [aG], nil) | |
664 | + | if ($isInstanceOf(ai, "Boolean")) | |
665 | + | then ai | |
666 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
602 | 667 | } | |
603 | - | if (( | |
604 | - | then if ( | |
668 | + | if ((cr == cr)) | |
669 | + | then if (cr) | |
605 | 670 | then $Tuple2(nil, true) | |
606 | 671 | else { | |
607 | - | let cd = addressFromStringValue(valueOrElse(getString(this, q), "invalid assets store contract")) | |
608 | - | let bD = aA(B) | |
609 | - | let bW = { | |
610 | - | let ad = invoke(ai, "checkBalance", [az], nil) | |
611 | - | if ($isInstanceOf(ad, "Boolean")) | |
612 | - | then ad | |
613 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
614 | - | } | |
615 | - | let ce = { | |
616 | - | let ad = invoke(cd, "isVerifiedREADONLY", [D], nil) | |
617 | - | if ($isInstanceOf(ad, "Boolean")) | |
618 | - | then ad | |
619 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
620 | - | } | |
621 | - | let cf = { | |
622 | - | let ad = invoke(cd, "isVerifiedREADONLY", [E], nil) | |
623 | - | if ($isInstanceOf(ad, "Boolean")) | |
624 | - | then ad | |
625 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
626 | - | } | |
627 | - | let cg = if (if (if (if (!(bD)) | |
628 | - | then bW | |
629 | - | else false) | |
630 | - | then ce | |
631 | - | else false) | |
632 | - | then cf | |
633 | - | else false) | |
634 | - | then invoke(ai, "setWxEmissionPoolLabel", [D, E], nil) | |
635 | - | else unit | |
636 | - | if ((cg == cg)) | |
637 | - | then { | |
638 | - | let bz = valueOrElse(getInteger(this, P(bZ)), 0) | |
639 | - | let bR = valueOrElse(getInteger(this, J(B, bZ)), 0) | |
640 | - | let ch = if (if (if ((bz == 0)) | |
641 | - | then true | |
642 | - | else !(bD)) | |
643 | - | then true | |
644 | - | else !(bW)) | |
645 | - | then 0 | |
646 | - | else fraction(bR, b, bz) | |
647 | - | let ci = invoke(ai, "modifyWeight", [az, ch], nil) | |
648 | - | if ((ci == ci)) | |
649 | - | then $Tuple2([IntegerEntry(N(B, bZ), ch)], false) | |
650 | - | else throw("Strict value is not equal to itself.") | |
651 | - | } | |
672 | + | let cs = addressFromStringValue(valueOrErrorMessage(getString(an, t), "invalid assets store contract")) | |
673 | + | let bG = valueOrElse(getInteger(this, U(co)), 0) | |
674 | + | let ci = valueOrElse(getInteger(this, O(E, co)), 0) | |
675 | + | let ct = if ((bG == 0)) | |
676 | + | then 0 | |
677 | + | else fraction(ci, b, bG) | |
678 | + | let bX = invoke(an, "modifyWeight", [aG, ct], nil) | |
679 | + | if ((bX == bX)) | |
680 | + | then $Tuple2([IntegerEntry(S(E, co), ct)], false) | |
652 | 681 | else throw("Strict value is not equal to itself.") | |
653 | 682 | } | |
654 | 683 | else throw("Strict value is not equal to itself.") | |
660 | 689 | ||
661 | 690 | ||
662 | 691 | ||
663 | - | @Callable( | |
692 | + | @Callable(bk) | |
664 | 693 | func finalizeHelper () = { | |
665 | - | let | |
666 | - | let | |
667 | - | let | |
668 | - | let | |
669 | - | let | |
670 | - | let | |
671 | - | let | |
672 | - | if (if (if ((height >= | |
673 | - | then ( | |
694 | + | let cn = valueOrElse(getBoolean(A), false) | |
695 | + | let k = valueOrElse(getInteger(this, l), 0) | |
696 | + | let cu = (k - 1) | |
697 | + | let bA = aj(this, B(k)) | |
698 | + | let bu = aj(this, h) | |
699 | + | let bB = (bA + bu) | |
700 | + | let bC = getInteger(this, u) | |
701 | + | if (if (if ((height >= bB)) | |
702 | + | then (bC == unit) | |
674 | 703 | else false) | |
675 | - | then !( | |
704 | + | then !(cn) | |
676 | 705 | else false) | |
677 | 706 | then { | |
678 | - | let | |
679 | - | let | |
680 | - | let | |
681 | - | let | |
682 | - | if ($isInstanceOf( | |
707 | + | let cv = (k + 1) | |
708 | + | let cw = getInteger(this, i) | |
709 | + | let cx = { | |
710 | + | let ae = cw | |
711 | + | if ($isInstanceOf(ae, "Int")) | |
683 | 712 | then { | |
684 | - | let | |
685 | - | [IntegerEntry( | |
713 | + | let bN = ae | |
714 | + | [IntegerEntry(h, bN), DeleteEntry(i)] | |
686 | 715 | } | |
687 | - | else if ($isInstanceOf( | |
716 | + | else if ($isInstanceOf(ae, "Unit")) | |
688 | 717 | then nil | |
689 | 718 | else throw("Match error") | |
690 | 719 | } | |
691 | - | $Tuple2(([IntegerEntry( | |
720 | + | $Tuple2(([IntegerEntry(B(cv), height), IntegerEntry(x, height), IntegerEntry(l, cv), IntegerEntry(u, d), IntegerEntry(j(k), bu)] ++ cx), true) | |
692 | 721 | } | |
693 | - | else if (if ( | |
694 | - | then ( | |
722 | + | else if (if (cn) | |
723 | + | then (bC == unit) | |
695 | 724 | else false) | |
696 | - | then $Tuple2([IntegerEntry( | |
697 | - | else if (( | |
725 | + | then $Tuple2([IntegerEntry(u, f)], true) | |
726 | + | else if ((bC == unit)) | |
698 | 727 | then $Tuple2(nil, false) | |
699 | - | else if (( | |
728 | + | else if ((bC == d)) | |
700 | 729 | then { | |
701 | - | let cn = getString(s) | |
702 | - | let co = getString(t) | |
703 | - | let Z = cn | |
704 | - | if ($isInstanceOf(Z, "Unit")) | |
730 | + | let cy = getString(v) | |
731 | + | let ae = cy | |
732 | + | if ($isInstanceOf(ae, "Unit")) | |
705 | 733 | then { | |
706 | - | let | |
707 | - | if ($isInstanceOf( | |
708 | - | then $Tuple2([IntegerEntry( | |
709 | - | else if ($isInstanceOf( | |
734 | + | let cz = getString(aO(aL)) | |
735 | + | if ($isInstanceOf(cz, "Unit")) | |
736 | + | then $Tuple2([IntegerEntry(u, e), DeleteEntry(v)], true) | |
737 | + | else if ($isInstanceOf(cz, "String")) | |
710 | 738 | then { | |
711 | - | let | |
712 | - | $Tuple2([StringEntry( | |
739 | + | let cA = cz | |
740 | + | $Tuple2([StringEntry(v, cA)], true) | |
713 | 741 | } | |
714 | 742 | else throw("Match error") | |
715 | 743 | } | |
716 | - | else if ($isInstanceOf( | |
744 | + | else if ($isInstanceOf(ae, "String")) | |
717 | 745 | then { | |
718 | - | let bI = Z | |
719 | - | let B = ag(bI) | |
720 | - | let cr = { | |
721 | - | let cp = co | |
722 | - | if ($isInstanceOf(cp, "Unit")) | |
723 | - | then getString(aH(aF(B))) | |
724 | - | else if ($isInstanceOf(cp, "String")) | |
746 | + | let bP = ae | |
747 | + | let cB = getString(aU(aL, bP)) | |
748 | + | if ((cB == cB)) | |
749 | + | then { | |
750 | + | let cr = invoke(this, "processPoolBalanceINTERNAL", [bP], nil) | |
751 | + | if ((cr == cr)) | |
725 | 752 | then { | |
726 | - | let cs = cp | |
727 | - | let ct = getString(aN(aF(B), cs)) | |
728 | - | if ((ct == ct)) | |
753 | + | let cz = cB | |
754 | + | if ($isInstanceOf(cz, "Unit")) | |
755 | + | then $Tuple2([IntegerEntry(u, e), DeleteEntry(v)], true) | |
756 | + | else if ($isInstanceOf(cz, "String")) | |
757 | + | then { | |
758 | + | let cA = cz | |
759 | + | $Tuple2([StringEntry(v, cA)], true) | |
760 | + | } | |
761 | + | else throw("Match error") | |
762 | + | } | |
763 | + | else throw("Strict value is not equal to itself.") | |
764 | + | } | |
765 | + | else throw("Strict value is not equal to itself.") | |
766 | + | } | |
767 | + | else throw("Match error") | |
768 | + | } | |
769 | + | else if ((bC == e)) | |
770 | + | then { | |
771 | + | let cy = getString(v) | |
772 | + | let cC = getString(w) | |
773 | + | let ae = cy | |
774 | + | if ($isInstanceOf(ae, "Unit")) | |
775 | + | then { | |
776 | + | let cz = getString(aO(aL)) | |
777 | + | if ($isInstanceOf(cz, "Unit")) | |
778 | + | then $Tuple2([IntegerEntry(u, f), DeleteEntry(v), DeleteEntry(w)], true) | |
779 | + | else if ($isInstanceOf(cz, "String")) | |
780 | + | then { | |
781 | + | let cD = cz | |
782 | + | $Tuple2([StringEntry(v, cD)], true) | |
783 | + | } | |
784 | + | else throw("Match error") | |
785 | + | } | |
786 | + | else if ($isInstanceOf(ae, "String")) | |
787 | + | then { | |
788 | + | let bP = ae | |
789 | + | let E = al(bP) | |
790 | + | let cE = { | |
791 | + | let cz = cC | |
792 | + | if ($isInstanceOf(cz, "Unit")) | |
793 | + | then getString(aO(aM(E))) | |
794 | + | else if ($isInstanceOf(cz, "String")) | |
795 | + | then { | |
796 | + | let cF = cz | |
797 | + | let cG = getString(aU(aM(E), cF)) | |
798 | + | if ((cG == cG)) | |
799 | + | then { | |
800 | + | let cH = invoke(this, "processVoteINTERNAL", [bP, cF], nil) | |
801 | + | if ((cH == cH)) | |
802 | + | then cG | |
803 | + | else throw("Strict value is not equal to itself.") | |
804 | + | } | |
805 | + | else throw("Strict value is not equal to itself.") | |
806 | + | } | |
807 | + | else throw("Match error") | |
808 | + | } | |
809 | + | let cz = cE | |
810 | + | if ($isInstanceOf(cz, "Unit")) | |
811 | + | then { | |
812 | + | let cB = getString(aU(aL, bP)) | |
813 | + | let cI = cB | |
814 | + | if ($isInstanceOf(cI, "Unit")) | |
815 | + | then $Tuple2([IntegerEntry(u, f), DeleteEntry(v), DeleteEntry(w)], true) | |
816 | + | else if ($isInstanceOf(cI, "String")) | |
729 | 817 | then { | |
730 | - | let cu = invoke(this, "processVoteINTERNAL", [bI, cs], nil) | |
731 | - | if ((cu == cu)) | |
732 | - | then ct | |
733 | - | else throw("Strict value is not equal to itself.") | |
818 | + | let bg = cI | |
819 | + | $Tuple2([StringEntry(v, bg), DeleteEntry(w)], true) | |
734 | 820 | } | |
735 | - | else throw("Strict value is not equal to itself.") | |
821 | + | else throw("Match error") | |
822 | + | } | |
823 | + | else if ($isInstanceOf(cz, "String")) | |
824 | + | then { | |
825 | + | let cJ = cz | |
826 | + | $Tuple2([StringEntry(w, cJ)], true) | |
736 | 827 | } | |
737 | 828 | else throw("Match error") | |
738 | 829 | } | |
739 | - | let cp = cr | |
740 | - | if ($isInstanceOf(cp, "Unit")) | |
830 | + | else throw("Match error") | |
831 | + | } | |
832 | + | else if ((bC == f)) | |
833 | + | then { | |
834 | + | let cy = getString(v) | |
835 | + | let ae = cy | |
836 | + | if ($isInstanceOf(ae, "Unit")) | |
837 | + | then { | |
838 | + | let cz = getString(aO(aL)) | |
839 | + | if ($isInstanceOf(cz, "Unit")) | |
840 | + | then { | |
841 | + | let bV = if (cn) | |
842 | + | then [DeleteEntry(u), DeleteEntry(A)] | |
843 | + | else [DeleteEntry(u), BooleanEntry(C(cu), true), IntegerEntry(y, k), IntegerEntry(z, bA)] | |
844 | + | let cK = aJ() | |
845 | + | if ((cK == cK)) | |
846 | + | then $Tuple2(bV, true) | |
847 | + | else throw("Strict value is not equal to itself.") | |
848 | + | } | |
849 | + | else if ($isInstanceOf(cz, "String")) | |
850 | + | then { | |
851 | + | let cA = cz | |
852 | + | $Tuple2([StringEntry(v, cA)], true) | |
853 | + | } | |
854 | + | else throw("Match error") | |
855 | + | } | |
856 | + | else if ($isInstanceOf(ae, "String")) | |
741 | 857 | then { | |
742 | - | let cv = getString(aN(aE, bI)) | |
743 | - | let cw = cv | |
744 | - | if ($isInstanceOf(cw, "Unit")) | |
745 | - | then $Tuple2([IntegerEntry(r, e), DeleteEntry(s), DeleteEntry(t)], true) | |
746 | - | else if ($isInstanceOf(cw, "String")) | |
747 | - | then { | |
748 | - | let aZ = cw | |
749 | - | $Tuple2([StringEntry(s, aZ), DeleteEntry(t)], true) | |
858 | + | let bP = ae | |
859 | + | let cB = getString(aU(aL, bP)) | |
860 | + | if ((cB == cB)) | |
861 | + | then { | |
862 | + | let cr = { | |
863 | + | let ai = invoke(this, "processPoolINTERNAL", [bP, cn], nil) | |
864 | + | if ($isInstanceOf(ai, "Boolean")) | |
865 | + | then ai | |
866 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
750 | 867 | } | |
751 | - | else throw("Match error") | |
752 | - | } | |
753 | - | else if ($isInstanceOf(cp, "String")) | |
754 | - | then { | |
755 | - | let cx = cp | |
756 | - | $Tuple2([StringEntry(t, cx)], true) | |
757 | - | } | |
758 | - | else throw("Match error") | |
759 | - | } | |
760 | - | else throw("Match error") | |
761 | - | } | |
762 | - | else if ((bv == e)) | |
763 | - | then { | |
764 | - | let cn = getString(s) | |
765 | - | let Z = cn | |
766 | - | if ($isInstanceOf(Z, "Unit")) | |
767 | - | then { | |
768 | - | let cp = getString(aH(aE)) | |
769 | - | if ($isInstanceOf(cp, "Unit")) | |
770 | - | then { | |
771 | - | let bX = if (bY) | |
772 | - | then [DeleteEntry(r), DeleteEntry(x)] | |
773 | - | else [DeleteEntry(r), BooleanEntry(z(cj), true), IntegerEntry(v, i), IntegerEntry(w, bt)] | |
774 | - | let cy = aC() | |
775 | - | if ((cy == cy)) | |
776 | - | then $Tuple2(bX, true) | |
868 | + | if ((cr == cr)) | |
869 | + | then if (cr) | |
870 | + | then $Tuple2(nil, true) | |
871 | + | else { | |
872 | + | let cz = cB | |
873 | + | if ($isInstanceOf(cz, "Unit")) | |
874 | + | then { | |
875 | + | let bV = if (cn) | |
876 | + | then [DeleteEntry(u), DeleteEntry(A), DeleteEntry(v)] | |
877 | + | else [DeleteEntry(u), BooleanEntry(C(cu), true), IntegerEntry(y, k), IntegerEntry(z, bA), DeleteEntry(v)] | |
878 | + | let cK = aJ() | |
879 | + | if ((cK == cK)) | |
880 | + | then $Tuple2(bV, true) | |
881 | + | else throw("Strict value is not equal to itself.") | |
882 | + | } | |
883 | + | else if ($isInstanceOf(cz, "String")) | |
884 | + | then { | |
885 | + | let cA = cz | |
886 | + | $Tuple2([StringEntry(v, cA)], true) | |
887 | + | } | |
888 | + | else throw("Match error") | |
889 | + | } | |
890 | + | else throw("Strict value is not equal to itself.") | |
891 | + | } | |
777 | 892 | else throw("Strict value is not equal to itself.") | |
778 | 893 | } | |
779 | - | else if ($isInstanceOf(cp, "String")) | |
780 | - | then { | |
781 | - | let cz = cp | |
782 | - | $Tuple2([StringEntry(s, cz)], true) | |
783 | - | } | |
784 | - | else throw("Match error") | |
785 | - | } | |
786 | - | else if ($isInstanceOf(Z, "String")) | |
787 | - | then { | |
788 | - | let bI = Z | |
789 | - | let cv = getString(aN(aE, bI)) | |
790 | - | if ((cv == cv)) | |
791 | - | then { | |
792 | - | let cc = { | |
793 | - | let ad = invoke(this, "processPoolINTERNAL", [bI, bY], nil) | |
794 | - | if ($isInstanceOf(ad, "Boolean")) | |
795 | - | then ad | |
796 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
797 | - | } | |
798 | - | if ((cc == cc)) | |
799 | - | then if (cc) | |
800 | - | then $Tuple2(nil, true) | |
801 | - | else { | |
802 | - | let cp = cv | |
803 | - | if ($isInstanceOf(cp, "Unit")) | |
804 | - | then { | |
805 | - | let bX = if (bY) | |
806 | - | then [DeleteEntry(r), DeleteEntry(x), DeleteEntry(s)] | |
807 | - | else [DeleteEntry(r), BooleanEntry(z(cj), true), IntegerEntry(v, i), IntegerEntry(w, bt), DeleteEntry(s)] | |
808 | - | let cy = aC() | |
809 | - | if ((cy == cy)) | |
810 | - | then $Tuple2(bX, true) | |
811 | - | else throw("Strict value is not equal to itself.") | |
812 | - | } | |
813 | - | else if ($isInstanceOf(cp, "String")) | |
814 | - | then { | |
815 | - | let cz = cp | |
816 | - | $Tuple2([StringEntry(s, cz)], true) | |
817 | - | } | |
818 | - | else throw("Match error") | |
819 | - | } | |
820 | - | else throw("Strict value is not equal to itself.") | |
821 | - | } | |
822 | - | else throw("Strict value is not equal to itself.") | |
823 | - | } | |
824 | - | else throw("Match error") | |
825 | - | } | |
826 | - | else U("finalization is broken") | |
894 | + | else throw("Match error") | |
895 | + | } | |
896 | + | else Z("finalization is broken") | |
827 | 897 | } | |
828 | 898 | ||
829 | 899 | ||
830 | 900 | ||
831 | - | @Callable( | |
832 | - | func finalizeWrapper ( | |
833 | - | let | |
834 | - | let | |
835 | - | let | |
836 | - | if ($isInstanceOf( | |
837 | - | then | |
838 | - | else throw(($getType( | |
901 | + | @Callable(bk) | |
902 | + | func finalizeWrapper (cL) = { | |
903 | + | let cM = addressFromStringValue(getStringValue(this, p)) | |
904 | + | let cN = { | |
905 | + | let ai = invoke(this, "finalizeHelper", nil, nil) | |
906 | + | if ($isInstanceOf(ai, "Boolean")) | |
907 | + | then ai | |
908 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
839 | 909 | } | |
840 | - | if (( | |
841 | - | then if (!( | |
842 | - | then if (( | |
843 | - | then | |
910 | + | if ((cN == cN)) | |
911 | + | then if (!(cN)) | |
912 | + | then if ((cL == 0)) | |
913 | + | then Z("Current voting is not over yet") | |
844 | 914 | else { | |
845 | - | let | |
846 | - | if (( | |
915 | + | let cO = invoke(cM, "finalize", nil, nil) | |
916 | + | if ((cO == cO)) | |
847 | 917 | then $Tuple2(nil, unit) | |
848 | 918 | else throw("Strict value is not equal to itself.") | |
849 | 919 | } | |
850 | 920 | else { | |
851 | - | let | |
852 | - | if (( | |
921 | + | let cP = valueOrElse(getInteger(this, m), c) | |
922 | + | if ((cP > cL)) | |
853 | 923 | then { | |
854 | - | let | |
855 | - | if (( | |
924 | + | let cO = invoke(this, "finalizeWrapper", [(cL + 1)], nil) | |
925 | + | if ((cO == cO)) | |
856 | 926 | then $Tuple2(nil, unit) | |
857 | 927 | else throw("Strict value is not equal to itself.") | |
858 | 928 | } | |
863 | 933 | ||
864 | 934 | ||
865 | 935 | ||
866 | - | @Callable( | |
936 | + | @Callable(bk) | |
867 | 937 | func finalize () = { | |
868 | - | let | |
869 | - | if (( | |
938 | + | let cO = invoke(this, "finalizeWrapper", [0], nil) | |
939 | + | if ((cO == cO)) | |
870 | 940 | then $Tuple2(nil, unit) | |
871 | 941 | else throw("Strict value is not equal to itself.") | |
872 | 942 | } | |
873 | 943 | ||
874 | 944 | ||
875 | 945 | ||
876 | - | @Callable( | |
877 | - | func containsNodeREADONLY ( | |
946 | + | @Callable(bk) | |
947 | + | func containsNodeREADONLY (aP,aT) = $Tuple2(nil, aV(aP, aT)) | |
878 | 948 | ||
879 | 949 | ||
880 | 950 | ||
881 | - | @Callable( | |
882 | - | func insertNode ( | |
883 | - | let | |
884 | - | if (( | |
885 | - | then $Tuple2( | |
951 | + | @Callable(bk) | |
952 | + | func insertNode (aP,aT) = { | |
953 | + | let bQ = bm(bk) | |
954 | + | if ((bQ == bQ)) | |
955 | + | then $Tuple2(aZ(aP, aT), unit) | |
886 | 956 | else throw("Strict value is not equal to itself.") | |
887 | 957 | } | |
888 | 958 | ||
889 | 959 | ||
890 | 960 | ||
891 | - | @Callable( | |
892 | - | func deleteNode ( | |
893 | - | let | |
894 | - | if (( | |
895 | - | then $Tuple2( | |
961 | + | @Callable(bk) | |
962 | + | func deleteNode (aP,aT) = { | |
963 | + | let bQ = bm(bk) | |
964 | + | if ((bQ == bQ)) | |
965 | + | then $Tuple2(bc(aP, aT), unit) | |
896 | 966 | else throw("Strict value is not equal to itself.") | |
897 | 967 | } | |
898 | 968 | ||
899 | 969 | ||
900 | 970 | ||
901 | - | @Callable( | |
971 | + | @Callable(bk) | |
902 | 972 | func isFinalizationInProgress () = { | |
903 | - | let | |
904 | - | let | |
905 | - | $Tuple2(nil, | |
973 | + | let bC = getInteger(this, u) | |
974 | + | let cQ = (bC != unit) | |
975 | + | $Tuple2(nil, cQ) | |
906 | 976 | } | |
907 | 977 | ||
908 | 978 | ||
909 | 979 | ||
910 | - | @Callable( | |
911 | - | func deletePool ( | |
912 | - | let | |
980 | + | @Callable(bk) | |
981 | + | func deletePool (G,H) = { | |
982 | + | let bQ = if (if ((bk.caller == an)) | |
913 | 983 | then true | |
914 | - | else | |
984 | + | else bm(bk)) | |
915 | 985 | then true | |
916 | - | else | |
917 | - | if (( | |
986 | + | else Z("Permission denied") | |
987 | + | if ((bQ == bQ)) | |
918 | 988 | then { | |
919 | - | let | |
920 | - | let | |
921 | - | let | |
922 | - | let | |
923 | - | then | |
989 | + | let aP = "pools" | |
990 | + | let E = $Tuple2(G, H) | |
991 | + | let aT = makeString([G, H], a) | |
992 | + | let bV = if (aV(aP, aT)) | |
993 | + | then bc(aP, aT) | |
924 | 994 | else nil | |
925 | - | ([DeleteEntry( | |
995 | + | ([DeleteEntry(D(E))] ++ bV) | |
926 | 996 | } | |
927 | 997 | else throw("Strict value is not equal to itself.") | |
928 | 998 | } | |
929 | 999 | ||
930 | 1000 | ||
931 | - | @Verifier(cG) | |
932 | - | func cH () = { | |
933 | - | let cI = { | |
934 | - | let Z = ba() | |
935 | - | if ($isInstanceOf(Z, "ByteVector")) | |
1001 | + | ||
1002 | + | @Callable(bk) | |
1003 | + | func resume (G,H) = { | |
1004 | + | let aG = aw(G, H) | |
1005 | + | let cR = { | |
1006 | + | let ai = invoke(an, "checkBalance", [aG], nil) | |
1007 | + | if ($isInstanceOf(ai, "Boolean")) | |
1008 | + | then ai | |
1009 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1010 | + | } | |
1011 | + | let cS = bk.payments[0] | |
1012 | + | let cs = addressFromStringValue(getStringValue(this, t)) | |
1013 | + | let cT = "%s__config" | |
1014 | + | let cU = 1 | |
1015 | + | let bs = addressFromStringValue(ah(this, r)) | |
1016 | + | let cV = fromBase58String(split(getStringValue(bs, cT), a)[cU]) | |
1017 | + | let cW = { | |
1018 | + | let ai = invoke(cs, "isVerifiedREADONLY", [G], nil) | |
1019 | + | if ($isInstanceOf(ai, "Boolean")) | |
1020 | + | then ai | |
1021 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1022 | + | } | |
1023 | + | let cX = { | |
1024 | + | let ai = invoke(cs, "isVerifiedREADONLY", [H], nil) | |
1025 | + | if ($isInstanceOf(ai, "Boolean")) | |
1026 | + | then ai | |
1027 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1028 | + | } | |
1029 | + | let cY = valueOrElse(getInteger(this, n), g) | |
1030 | + | let bv = [if (cR) | |
1031 | + | then true | |
1032 | + | else Z("insufficient balances"), if ((size(bk.payments) == 1)) | |
1033 | + | then true | |
1034 | + | else Z("1 payment is required"), if ((cS.assetId == cV)) | |
1035 | + | then true | |
1036 | + | else Z("invalid payment asset id"), if ((cS.amount == cY)) | |
1037 | + | then true | |
1038 | + | else Z("invalid payment amount"), if (if (cW) | |
1039 | + | then cX | |
1040 | + | else false) | |
1041 | + | then true | |
1042 | + | else Z("both assets should be verified")] | |
1043 | + | if ((bv == bv)) | |
1044 | + | then { | |
1045 | + | let E = $Tuple2(G, H) | |
1046 | + | let bw = ([BooleanEntry(D(E), true)] ++ aZ(aL, ak(E))) | |
1047 | + | $Tuple2(bw, unit) | |
1048 | + | } | |
1049 | + | else throw("Strict value is not equal to itself.") | |
1050 | + | } | |
1051 | + | ||
1052 | + | ||
1053 | + | @Verifier(cZ) | |
1054 | + | func da () = { | |
1055 | + | let db = { | |
1056 | + | let ae = bh() | |
1057 | + | if ($isInstanceOf(ae, "ByteVector")) | |
936 | 1058 | then { | |
937 | - | let | |
938 | - | | |
1059 | + | let bl = ae | |
1060 | + | bl | |
939 | 1061 | } | |
940 | - | else if ($isInstanceOf( | |
941 | - | then | |
1062 | + | else if ($isInstanceOf(ae, "Unit")) | |
1063 | + | then cZ.senderPublicKey | |
942 | 1064 | else throw("Match error") | |
943 | 1065 | } | |
944 | - | sigVerify( | |
1066 | + | sigVerify(cZ.bodyBytes, cZ.proofs[0], db) | |
945 | 1067 | } | |
946 | 1068 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "__" | |
5 | 5 | ||
6 | 6 | let b = 100000000 | |
7 | 7 | ||
8 | 8 | let c = 10 | |
9 | 9 | ||
10 | 10 | let d = 0 | |
11 | 11 | ||
12 | 12 | let e = 1 | |
13 | 13 | ||
14 | - | let f = | |
14 | + | let f = 2 | |
15 | 15 | ||
16 | - | let g = | |
16 | + | let g = 500000000000 | |
17 | 17 | ||
18 | - | func h (i) = makeString(["%s%d", "epochLength", toString(i)], a) | |
18 | + | let h = makeString(["%s", "epochLength"], a) | |
19 | + | ||
20 | + | let i = makeString(["%s%s", "epochLength__new"], a) | |
21 | + | ||
22 | + | func j (k) = makeString(["%s%d", "epochLength", toString(k)], a) | |
19 | 23 | ||
20 | 24 | ||
21 | - | let | |
25 | + | let l = makeString(["%s", "currentEpoch"], a) | |
22 | 26 | ||
23 | - | let | |
27 | + | let m = makeString(["%s", "maxDepth"], a) | |
24 | 28 | ||
25 | - | let | |
29 | + | let n = makeString(["%s", "resumptionFee"], a) | |
26 | 30 | ||
27 | - | let | |
31 | + | let o = makeString(["%s", "votingEmissionCandidateContract"], a) | |
28 | 32 | ||
29 | - | let | |
33 | + | let p = makeString(["%s", "votingEmissionRateContract"], a) | |
30 | 34 | ||
31 | - | let | |
35 | + | let q = makeString(["%s", "factoryContract"], a) | |
32 | 36 | ||
33 | - | let | |
37 | + | let r = makeString(["%s", "boostingContract"], a) | |
34 | 38 | ||
35 | - | let | |
39 | + | let s = makeString(["%s", "stakingContract"], a) | |
36 | 40 | ||
37 | - | let | |
41 | + | let t = makeString(["%s", "assetsStoreContract"], a) | |
38 | 42 | ||
39 | - | let | |
43 | + | let u = makeString(["%s", "finalizationStage"], a) | |
40 | 44 | ||
41 | - | let | |
45 | + | let v = makeString(["%s", "nextPool"], a) | |
42 | 46 | ||
43 | - | let | |
47 | + | let w = makeString(["%s", "nextUser"], a) | |
44 | 48 | ||
45 | - | let | |
49 | + | let x = makeString(["%s", "startHeight"], a) | |
46 | 50 | ||
47 | - | let | |
51 | + | let y = makeString(["%s", "currentEpochUi"], a) | |
48 | 52 | ||
49 | - | let | |
53 | + | let z = makeString(["%s", "startHeightUi"], a) | |
50 | 54 | ||
51 | - | func y (i) = makeString(["%s%d", "startHeight", toString(i)], a) | |
55 | + | let A = makeString(["%s", "force"], a) | |
56 | + | ||
57 | + | func B (k) = makeString(["%s%d", "startHeight", toString(k)], a) | |
52 | 58 | ||
53 | 59 | ||
54 | - | func | |
60 | + | func C (k) = makeString(["%s%d", "finalized", toString(k)], a) | |
55 | 61 | ||
56 | 62 | ||
57 | - | func | |
58 | - | let | |
59 | - | let | |
60 | - | let | |
61 | - | makeString(["%s%s%s", "inList", | |
63 | + | func D (E) = { | |
64 | + | let F = E | |
65 | + | let G = F._1 | |
66 | + | let H = F._2 | |
67 | + | makeString(["%s%s%s", "inList", G, H], a) | |
62 | 68 | } | |
63 | 69 | ||
64 | 70 | ||
65 | - | func F (G,i) = makeString(["%s%s%d", "used", toString(G), toString(i)], a) | |
66 | - | ||
67 | - | ||
68 | - | func H (B,G,i) = { | |
69 | - | let I = B | |
70 | - | let D = I._1 | |
71 | - | let E = I._2 | |
72 | - | makeString(["%s%s%s%s%d", "vote", D, E, toString(G), toString(i)], a) | |
71 | + | func I (E,k) = { | |
72 | + | let J = E | |
73 | + | let G = J._1 | |
74 | + | let H = J._2 | |
75 | + | makeString(["%s%s%s%d", "insufficientBalances", G, H, toString(k)], a) | |
73 | 76 | } | |
74 | 77 | ||
75 | 78 | ||
76 | - | func J (B,i) = { | |
77 | - | let K = B | |
78 | - | let D = K._1 | |
79 | - | let E = K._2 | |
80 | - | makeString(["%s%s%s%d", "votingResult", D, E, toString(i)], a) | |
79 | + | func K (L,k) = makeString(["%s%s%d", "used", toString(L), toString(k)], a) | |
80 | + | ||
81 | + | ||
82 | + | func M (E,L,k) = { | |
83 | + | let N = E | |
84 | + | let G = N._1 | |
85 | + | let H = N._2 | |
86 | + | makeString(["%s%s%s%s%d", "vote", G, H, toString(L), toString(k)], a) | |
81 | 87 | } | |
82 | 88 | ||
83 | 89 | ||
84 | - | func L (M,i) = makeString(["%s%s%d", "votingResultStaked", M, toString(i)], a) | |
85 | - | ||
86 | - | ||
87 | - | func N (B,i) = { | |
88 | - | let O = B | |
89 | - | let D = O._1 | |
90 | - | let E = O._2 | |
91 | - | makeString(["%s%s%s%d", "poolShare", D, E, toString(i)], a) | |
90 | + | func O (E,k) = { | |
91 | + | let P = E | |
92 | + | let G = P._1 | |
93 | + | let H = P._2 | |
94 | + | makeString(["%s%s%s%d", "votingResult", G, H, toString(k)], a) | |
92 | 95 | } | |
93 | 96 | ||
94 | 97 | ||
95 | - | func | |
98 | + | func Q (R,k) = makeString(["%s%s%d", "votingResultStaked", R, toString(k)], a) | |
96 | 99 | ||
97 | 100 | ||
98 | - | func Q (M,R) = makeString(["%s%s%s", "staked", R, M], a) | |
99 | - | ||
100 | - | ||
101 | - | func S (T) = makeString(["voting_emission.ride:", T], " ") | |
102 | - | ||
103 | - | ||
104 | - | func U (T) = throw(S(T)) | |
105 | - | ||
106 | - | ||
107 | - | func V (G,W,X) = { | |
108 | - | let Y = S(makeString(["mandatory ", toString(G), ".", W, " is not defined"], "")) | |
109 | - | valueOrErrorMessage({ | |
110 | - | let Z = X | |
111 | - | if ($isInstanceOf(Z, "String")) | |
112 | - | then { | |
113 | - | let aa = Z | |
114 | - | getString(G, W) | |
115 | - | } | |
116 | - | else if ($isInstanceOf(Z, "Int")) | |
117 | - | then { | |
118 | - | let ab = Z | |
119 | - | getInteger(G, W) | |
120 | - | } | |
121 | - | else U("invalid entry type") | |
122 | - | }, Y) | |
101 | + | func S (E,k) = { | |
102 | + | let T = E | |
103 | + | let G = T._1 | |
104 | + | let H = T._2 | |
105 | + | makeString(["%s%s%s%d", "poolShare", G, H, toString(k)], a) | |
123 | 106 | } | |
124 | 107 | ||
125 | 108 | ||
126 | - | func ac (G,W) = { | |
127 | - | let ad = V(G, W, "") | |
128 | - | if ($isInstanceOf(ad, "String")) | |
129 | - | then ad | |
130 | - | else throw(($getType(ad) + " couldn't be cast to String")) | |
109 | + | func U (k) = makeString(["%s%d", "totalVotes", toString(k)], a) | |
110 | + | ||
111 | + | ||
112 | + | func V (R,W) = makeString(["%s%s%s", "staked", W, R], a) | |
113 | + | ||
114 | + | ||
115 | + | func X (Y) = makeString(["voting_emission.ride:", Y], " ") | |
116 | + | ||
117 | + | ||
118 | + | func Z (Y) = throw(X(Y)) | |
119 | + | ||
120 | + | ||
121 | + | func aa (L,ab,ac) = { | |
122 | + | let ad = X(makeString(["mandatory ", toString(L), ".", ab, " is not defined"], "")) | |
123 | + | valueOrErrorMessage({ | |
124 | + | let ae = ac | |
125 | + | if ($isInstanceOf(ae, "String")) | |
126 | + | then { | |
127 | + | let af = ae | |
128 | + | getString(L, ab) | |
129 | + | } | |
130 | + | else if ($isInstanceOf(ae, "Int")) | |
131 | + | then { | |
132 | + | let ag = ae | |
133 | + | getInteger(L, ab) | |
134 | + | } | |
135 | + | else Z("invalid entry type") | |
136 | + | }, ad) | |
131 | 137 | } | |
132 | 138 | ||
133 | 139 | ||
134 | - | func | |
135 | - | let | |
136 | - | if ($isInstanceOf( | |
137 | - | then | |
138 | - | else throw(($getType( | |
140 | + | func ah (L,ab) = { | |
141 | + | let ai = aa(L, ab, "") | |
142 | + | if ($isInstanceOf(ai, "String")) | |
143 | + | then ai | |
144 | + | else throw(($getType(ai) + " couldn't be cast to String")) | |
139 | 145 | } | |
140 | 146 | ||
141 | 147 | ||
142 | - | func af (B) = ((B._1 + a) + B._2) | |
143 | - | ||
144 | - | ||
145 | - | func ag (aa) = { | |
146 | - | let ah = split(aa, a) | |
147 | - | if ((size(ah) == 2)) | |
148 | - | then $Tuple2(ah[0], ah[1]) | |
149 | - | else U("invalid pool string") | |
148 | + | func aj (L,ab) = { | |
149 | + | let ai = aa(L, ab, 0) | |
150 | + | if ($isInstanceOf(ai, "Int")) | |
151 | + | then ai | |
152 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
150 | 153 | } | |
151 | 154 | ||
152 | 155 | ||
153 | - | let ai = addressFromStringValue(ac(this, n)) | |
154 | - | ||
155 | - | let aj = 10 | |
156 | - | ||
157 | - | func ak () = "%s__factoryConfig" | |
156 | + | func ak (E) = ((E._1 + a) + E._2) | |
158 | 157 | ||
159 | 158 | ||
160 | - | func al (am) = split(ac(am, ak()), a) | |
161 | - | ||
162 | - | ||
163 | - | func an (ao) = addressFromStringValue(ao[aj]) | |
164 | - | ||
165 | - | ||
166 | - | func ap (D,E) = { | |
167 | - | func aq (ar) = ("%s%s%s__mappings__baseAsset2internalId__" + ar) | |
168 | - | ||
169 | - | func as (at,au) = (((("%d%d%s%s__" + toString(at)) + "__") + toString(au)) + "__mappings__poolAssets2PoolContract") | |
170 | - | ||
171 | - | func av (aw) = (("%s%s%s__" + aw) + "__mappings__poolContract2LpAsset") | |
172 | - | ||
173 | - | let ax = ae(ai, aq(D)) | |
174 | - | let ay = ae(ai, aq(E)) | |
175 | - | let aw = ac(ai, as(ax, ay)) | |
176 | - | let az = ac(ai, av(aw)) | |
177 | - | az | |
159 | + | func al (af) = { | |
160 | + | let am = split(af, a) | |
161 | + | if ((size(am) == 2)) | |
162 | + | then $Tuple2(am[0], am[1]) | |
163 | + | else Z("invalid pool string") | |
178 | 164 | } | |
179 | 165 | ||
180 | 166 | ||
181 | - | func aA (B) = { | |
182 | - | let aB = B | |
183 | - | let D = aB._1 | |
184 | - | let E = aB._2 | |
185 | - | let ad = invoke(ai, "checkWxEmissionPoolLabel", [D, E], nil) | |
186 | - | if ($isInstanceOf(ad, "Boolean")) | |
187 | - | then ad | |
188 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
167 | + | let an = addressFromStringValue(ah(this, q)) | |
168 | + | ||
169 | + | let ao = 10 | |
170 | + | ||
171 | + | func ap () = "%s__factoryConfig" | |
172 | + | ||
173 | + | ||
174 | + | func aq (ar) = split(ah(ar, ap()), a) | |
175 | + | ||
176 | + | ||
177 | + | func as (at) = addressFromStringValue(at[ao]) | |
178 | + | ||
179 | + | ||
180 | + | func au (G,H) = { | |
181 | + | let av = { | |
182 | + | let ai = invoke(an, "poolInfoREADONLY", [G, H], nil) | |
183 | + | if ($isInstanceOf(ai, "(Address, ByteVector)")) | |
184 | + | then ai | |
185 | + | else unit | |
186 | + | } | |
187 | + | av | |
189 | 188 | } | |
190 | 189 | ||
191 | 190 | ||
192 | - | func aC () = { | |
193 | - | let ao = al(ai) | |
194 | - | let aD = an(ao) | |
195 | - | invoke(aD, "deposit", nil, nil) | |
191 | + | func aw (G,H) = { | |
192 | + | func ax (ay) = ("%s%s%s__mappings__baseAsset2internalId__" + ay) | |
193 | + | ||
194 | + | func az (aA,aB) = (((("%d%d%s%s__" + toString(aA)) + "__") + toString(aB)) + "__mappings__poolAssets2PoolContract") | |
195 | + | ||
196 | + | func aC (aD) = (("%s%s%s__" + aD) + "__mappings__poolContract2LpAsset") | |
197 | + | ||
198 | + | let aE = aj(an, ax(G)) | |
199 | + | let aF = aj(an, ax(H)) | |
200 | + | let aD = ah(an, az(aE, aF)) | |
201 | + | let aG = ah(an, aC(aD)) | |
202 | + | aG | |
196 | 203 | } | |
197 | 204 | ||
198 | 205 | ||
199 | - | let aE = "pools" | |
200 | - | ||
201 | - | func aF (B) = { | |
202 | - | let aG = B | |
203 | - | let D = aG._1 | |
204 | - | let E = aG._2 | |
205 | - | makeString(["votes", D, E], a) | |
206 | + | func aH (E) = { | |
207 | + | let aI = E | |
208 | + | let G = aI._1 | |
209 | + | let H = aI._2 | |
210 | + | let ai = invoke(an, "checkWxEmissionPoolLabel", [G, H], nil) | |
211 | + | if ($isInstanceOf(ai, "Boolean")) | |
212 | + | then ai | |
213 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
206 | 214 | } | |
207 | 215 | ||
208 | 216 | ||
209 | - | func aH (aI) = { | |
210 | - | let aJ = if ((aI == aE)) | |
211 | - | then "%s%s" | |
212 | - | else "%s%s%s%s" | |
213 | - | makeString([aJ, aI, "head"], a) | |
217 | + | func aJ () = { | |
218 | + | let at = aq(an) | |
219 | + | let aK = as(at) | |
220 | + | invoke(aK, "deposit", nil, nil) | |
214 | 221 | } | |
215 | 222 | ||
216 | 223 | ||
217 | - | func aK (aI) = { | |
218 | - | let aJ = if ((aI == aE)) | |
219 | - | then "%s%s" | |
220 | - | else "%s%s%s%s" | |
221 | - | makeString([aJ, aI, "size"], a) | |
224 | + | let aL = "pools" | |
225 | + | ||
226 | + | func aM (E) = { | |
227 | + | let aN = E | |
228 | + | let G = aN._1 | |
229 | + | let H = aN._2 | |
230 | + | makeString(["votes", G, H], a) | |
222 | 231 | } | |
223 | 232 | ||
224 | 233 | ||
225 | - | func | |
226 | - | let | |
227 | - | then "%s%s | |
228 | - | else "%s%s%s%s | |
229 | - | makeString([ | |
234 | + | func aO (aP) = { | |
235 | + | let aQ = if ((aP == aL)) | |
236 | + | then "%s%s" | |
237 | + | else "%s%s%s%s" | |
238 | + | makeString([aQ, aP, "head"], a) | |
230 | 239 | } | |
231 | 240 | ||
232 | 241 | ||
233 | - | func | |
234 | - | let | |
235 | - | then "%s%s | |
236 | - | else "%s%s%s%s | |
237 | - | makeString([ | |
242 | + | func aR (aP) = { | |
243 | + | let aQ = if ((aP == aL)) | |
244 | + | then "%s%s" | |
245 | + | else "%s%s%s%s" | |
246 | + | makeString([aQ, aP, "size"], a) | |
238 | 247 | } | |
239 | 248 | ||
240 | 249 | ||
241 | - | func aO (aI,aM) = { | |
242 | - | let aP = getString(this, aH(aI)) | |
243 | - | let aQ = getString(this, aL(aI, aM)) | |
244 | - | let aR = getString(this, aN(aI, aM)) | |
245 | - | if (if ((aM == valueOrElse(aP, ""))) | |
246 | - | then true | |
247 | - | else (aQ != unit)) | |
248 | - | then true | |
249 | - | else (aR != unit) | |
250 | + | func aS (aP,aT) = { | |
251 | + | let aQ = if ((aP == aL)) | |
252 | + | then "%s%s%s%s" | |
253 | + | else "%s%s%s%s%s" | |
254 | + | makeString([aQ, aP, aT, "prev"], a) | |
250 | 255 | } | |
251 | 256 | ||
252 | 257 | ||
253 | - | func aS (aI,aM) = { | |
254 | - | let aP = getString(this, aH(aI)) | |
255 | - | let aT = valueOrElse(getInteger(this, aK(aI)), 0) | |
256 | - | let aU = if (!(aO(aI, aM))) | |
258 | + | func aU (aP,aT) = { | |
259 | + | let aQ = if ((aP == aL)) | |
260 | + | then "%s%s%s%s" | |
261 | + | else "%s%s%s%s%s" | |
262 | + | makeString([aQ, aP, aT, "next"], a) | |
263 | + | } | |
264 | + | ||
265 | + | ||
266 | + | func aV (aP,aT) = { | |
267 | + | let aW = getString(this, aO(aP)) | |
268 | + | let aX = getString(this, aS(aP, aT)) | |
269 | + | let aY = getString(this, aU(aP, aT)) | |
270 | + | if (if ((aT == valueOrElse(aW, ""))) | |
257 | 271 | then true | |
258 | - | else U("Node exists") | |
259 | - | if ((aU == aU)) | |
260 | - | then (([IntegerEntry(aK(aI), (aT + 1))] ++ (if ((aP != unit)) | |
261 | - | then [StringEntry(aN(aI, aM), value(aP)), StringEntry(aL(aI, value(aP)), aM)] | |
262 | - | else nil)) ++ [StringEntry(aH(aI), aM)]) | |
272 | + | else (aX != unit)) | |
273 | + | then true | |
274 | + | else (aY != unit) | |
275 | + | } | |
276 | + | ||
277 | + | ||
278 | + | func aZ (aP,aT) = { | |
279 | + | let aW = getString(this, aO(aP)) | |
280 | + | let ba = valueOrElse(getInteger(this, aR(aP)), 0) | |
281 | + | let bb = if (!(aV(aP, aT))) | |
282 | + | then true | |
283 | + | else Z("Node exists") | |
284 | + | if ((bb == bb)) | |
285 | + | then (([IntegerEntry(aR(aP), (ba + 1))] ++ (if ((aW != unit)) | |
286 | + | then [StringEntry(aU(aP, aT), value(aW)), StringEntry(aS(aP, value(aW)), aT)] | |
287 | + | else nil)) ++ [StringEntry(aO(aP), aT)]) | |
263 | 288 | else throw("Strict value is not equal to itself.") | |
264 | 289 | } | |
265 | 290 | ||
266 | 291 | ||
267 | - | func | |
268 | - | let | |
269 | - | let | |
270 | - | let | |
271 | - | let | |
272 | - | ([IntegerEntry( | |
273 | - | then ( | |
292 | + | func bc (aP,aT) = { | |
293 | + | let aW = getString(this, aO(aP)) | |
294 | + | let ba = valueOrElse(getInteger(this, aR(aP)), 0) | |
295 | + | let aX = getString(this, aS(aP, aT)) | |
296 | + | let aY = getString(this, aU(aP, aT)) | |
297 | + | ([IntegerEntry(aR(aP), (ba - 1))] ++ (if (if ((aX != unit)) | |
298 | + | then (aY != unit) | |
274 | 299 | else false) | |
275 | - | then [StringEntry( | |
276 | - | else if (( | |
277 | - | then [StringEntry( | |
278 | - | else if (( | |
279 | - | then [DeleteEntry( | |
280 | - | else if (( | |
281 | - | then [DeleteEntry( | |
282 | - | else | |
300 | + | then [StringEntry(aU(aP, value(aX)), value(aY)), StringEntry(aS(aP, value(aY)), value(aX)), DeleteEntry(aS(aP, aT)), DeleteEntry(aU(aP, aT))] | |
301 | + | else if ((aY != unit)) | |
302 | + | then [StringEntry(aO(aP), value(aY)), DeleteEntry(aU(aP, aT)), DeleteEntry(aS(aP, value(aY)))] | |
303 | + | else if ((aX != unit)) | |
304 | + | then [DeleteEntry(aS(aP, aT)), DeleteEntry(aU(aP, value(aX)))] | |
305 | + | else if ((aT == valueOrElse(aW, ""))) | |
306 | + | then [DeleteEntry(aO(aP))] | |
307 | + | else Z(((("invalid node: " + aP) + ".") + aT)))) | |
283 | 308 | } | |
284 | 309 | ||
285 | 310 | ||
286 | - | func | |
311 | + | func bd () = "%s__managerVaultAddress" | |
287 | 312 | ||
288 | 313 | ||
289 | - | func | |
314 | + | func be () = "%s__managerPublicKey" | |
290 | 315 | ||
291 | 316 | ||
292 | - | func | |
293 | - | let | |
294 | - | if ($isInstanceOf( | |
317 | + | func bf () = { | |
318 | + | let ae = getString(bd()) | |
319 | + | if ($isInstanceOf(ae, "String")) | |
295 | 320 | then { | |
296 | - | let | |
297 | - | addressFromStringValue( | |
321 | + | let bg = ae | |
322 | + | addressFromStringValue(bg) | |
298 | 323 | } | |
299 | 324 | else this | |
300 | 325 | } | |
301 | 326 | ||
302 | 327 | ||
303 | - | func | |
304 | - | let | |
305 | - | let | |
306 | - | if ($isInstanceOf( | |
328 | + | func bh () = { | |
329 | + | let bi = bf() | |
330 | + | let ae = getString(bi, be()) | |
331 | + | if ($isInstanceOf(ae, "String")) | |
307 | 332 | then { | |
308 | - | let | |
309 | - | fromBase58String( | |
333 | + | let bg = ae | |
334 | + | fromBase58String(bg) | |
310 | 335 | } | |
311 | - | else if ($isInstanceOf( | |
336 | + | else if ($isInstanceOf(ae, "Unit")) | |
312 | 337 | then unit | |
313 | 338 | else throw("Match error") | |
314 | 339 | } | |
315 | 340 | ||
316 | 341 | ||
317 | - | func | |
318 | - | let | |
319 | - | if ($isInstanceOf( | |
342 | + | func bj (bk) = { | |
343 | + | let ae = bh() | |
344 | + | if ($isInstanceOf(ae, "ByteVector")) | |
320 | 345 | then { | |
321 | - | let | |
322 | - | ( | |
346 | + | let bl = ae | |
347 | + | (bk.callerPublicKey == bl) | |
323 | 348 | } | |
324 | - | else if ($isInstanceOf( | |
325 | - | then ( | |
349 | + | else if ($isInstanceOf(ae, "Unit")) | |
350 | + | then (bk.caller == this) | |
326 | 351 | else throw("Match error") | |
327 | 352 | } | |
328 | 353 | ||
329 | 354 | ||
330 | - | func | |
355 | + | func bm (bk) = if (bj(bk)) | |
331 | 356 | then true | |
332 | 357 | else throw("permission denied") | |
333 | 358 | ||
334 | 359 | ||
335 | - | func | |
360 | + | func bn (bk) = if ((bk.caller == this)) | |
336 | 361 | then true | |
337 | 362 | else throw("permission denied") | |
338 | 363 | ||
339 | 364 | ||
340 | - | @Callable( | |
341 | - | func getUserGwxAmountAtHeight ( | |
342 | - | let | |
365 | + | @Callable(bk) | |
366 | + | func getUserGwxAmountAtHeight (bo,bp) = { | |
367 | + | let bq = valueOrErrorMessage(addressFromString(ah(this, r)), X("invalid boosting contract address")) | |
343 | 368 | $Tuple2(nil, { | |
344 | - | let | |
345 | - | if ($isInstanceOf( | |
346 | - | then | |
347 | - | else throw(($getType( | |
369 | + | let ai = invoke(bq, "getUserGwxAmountAtHeightREADONLY", [bo, bp], nil) | |
370 | + | if ($isInstanceOf(ai, "Int")) | |
371 | + | then ai | |
372 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
348 | 373 | }) | |
349 | 374 | } | |
350 | 375 | ||
351 | 376 | ||
352 | 377 | ||
353 | - | @Callable( | |
354 | - | func constructor ( | |
355 | - | let | |
378 | + | @Callable(bk) | |
379 | + | func constructor (an,br,bs,bt,bu) = { | |
380 | + | let bv = [bm(bk), if ((addressFromString(an) != unit)) | |
356 | 381 | then true | |
357 | - | else "invalid factory contract address", if ((addressFromString( | |
382 | + | else "invalid factory contract address", if ((addressFromString(br) != unit)) | |
358 | 383 | then true | |
359 | - | else "invalid voting emission candidate contract address", if ((addressFromString( | |
384 | + | else "invalid voting emission candidate contract address", if ((addressFromString(bs) != unit)) | |
360 | 385 | then true | |
361 | - | else "invalid boosting contract address", if ((addressFromString( | |
386 | + | else "invalid boosting contract address", if ((addressFromString(bt) != unit)) | |
362 | 387 | then true | |
363 | - | else "invalid staking contract address", if (( | |
388 | + | else "invalid staking contract address", if ((bu > 0)) | |
364 | 389 | then true | |
365 | - | else | |
366 | - | if (( | |
367 | - | then $Tuple2([StringEntry( | |
390 | + | else Z("invalid epoch length")] | |
391 | + | if ((bv == bv)) | |
392 | + | then $Tuple2([StringEntry(q, an), StringEntry(o, br), StringEntry(r, bs), StringEntry(s, bt), IntegerEntry(h, bu)], unit) | |
368 | 393 | else throw("Strict value is not equal to itself.") | |
369 | 394 | } | |
370 | 395 | ||
371 | 396 | ||
372 | 397 | ||
373 | - | @Callable( | |
374 | - | func create ( | |
375 | - | let | |
398 | + | @Callable(bk) | |
399 | + | func create (G,H) = { | |
400 | + | let bv = [if ((toBase58String(bk.caller.bytes) == valueOrElse(getString(this, o), ""))) | |
376 | 401 | then true | |
377 | - | else | |
378 | - | if (( | |
402 | + | else bm(bk)] | |
403 | + | if ((bv == bv)) | |
379 | 404 | then { | |
380 | - | let | |
381 | - | let | |
382 | - | let | |
383 | - | let | |
405 | + | let E = $Tuple2(G, H) | |
406 | + | let bw = ([BooleanEntry(D(E), true)] ++ aZ(aL, ak(E))) | |
407 | + | let bx = (getInteger(this, l) == unit) | |
408 | + | let by = if (bx) | |
384 | 409 | then { | |
385 | - | let | |
386 | - | [IntegerEntry( | |
410 | + | let k = 0 | |
411 | + | [IntegerEntry(l, k), IntegerEntry(B(k), height), IntegerEntry(x, height), IntegerEntry(y, k), IntegerEntry(z, height)] | |
387 | 412 | } | |
388 | 413 | else nil | |
389 | - | $Tuple2(( | |
414 | + | $Tuple2((bw ++ by), unit) | |
390 | 415 | } | |
391 | 416 | else throw("Strict value is not equal to itself.") | |
392 | 417 | } | |
393 | 418 | ||
394 | 419 | ||
395 | 420 | ||
396 | - | @Callable( | |
397 | - | func vote ( | |
398 | - | let | |
399 | - | let | |
400 | - | let | |
401 | - | let | |
402 | - | let | |
403 | - | let | |
404 | - | let | |
405 | - | let | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | if ($isInstanceOf( | |
411 | - | then | |
412 | - | else throw(($getType( | |
421 | + | @Callable(bk) | |
422 | + | func vote (G,H,bz) = { | |
423 | + | let E = $Tuple2(G, H) | |
424 | + | let k = valueOrElse(getInteger(this, l), 0) | |
425 | + | let bA = aj(this, B(k)) | |
426 | + | let bu = aj(this, h) | |
427 | + | let bB = (bA + bu) | |
428 | + | let bC = getInteger(this, u) | |
429 | + | let bD = valueOrElse(getInteger(this, K(bk.caller, k)), 0) | |
430 | + | let bE = valueOrElse(getInteger(this, M(E, bk.caller, k)), 0) | |
431 | + | let bF = valueOrElse(getInteger(this, O(E, k)), 0) | |
432 | + | let bG = valueOrElse(getInteger(this, U(k)), 0) | |
433 | + | let bH = { | |
434 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [toBase58String(bk.caller.bytes), bB], nil) | |
435 | + | if ($isInstanceOf(ai, "Int")) | |
436 | + | then ai | |
437 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
413 | 438 | } | |
414 | - | let | |
415 | - | let | |
416 | - | let | |
417 | - | let | |
439 | + | let bI = (bH - bD) | |
440 | + | let bJ = (bE + bz) | |
441 | + | let bK = aH(E) | |
442 | + | let bv = [if ((getBoolean(D(E)) != unit)) | |
418 | 443 | then true | |
419 | - | else | |
444 | + | else Z("invalid assets"), if ((bB > height)) | |
420 | 445 | then true | |
421 | - | else | |
446 | + | else Z("invalid height"), if ((bC == unit)) | |
422 | 447 | then true | |
423 | - | else | |
448 | + | else Z("finalization in progress"), if ((bH > 0)) | |
424 | 449 | then true | |
425 | - | else | |
426 | - | then ( | |
450 | + | else Z("you do not have gWX"), if (if ((bz > 0)) | |
451 | + | then (bI >= bz) | |
427 | 452 | else false) | |
428 | 453 | then true | |
429 | - | else | |
454 | + | else Z("invalid amount"), if (bK) | |
430 | 455 | then true | |
431 | - | else | |
432 | - | if (( | |
456 | + | else Z("pool hasn't WX_EMISSION label")] | |
457 | + | if ((bv == bv)) | |
433 | 458 | then { | |
434 | - | let | |
435 | - | let | |
436 | - | let | |
459 | + | let bL = aM(E) | |
460 | + | let W = toString(bk.caller) | |
461 | + | let bM = if (aV(bL, W)) | |
437 | 462 | then nil | |
438 | - | else | |
439 | - | $Tuple2(([IntegerEntry( | |
463 | + | else aZ(bL, W) | |
464 | + | $Tuple2(([IntegerEntry(K(bk.caller, k), (bD + bz)), IntegerEntry(M(E, bk.caller, k), bJ), IntegerEntry(O(E, k), (bF + bz)), IntegerEntry(U(k), (bG + bz))] ++ bM), unit) | |
440 | 465 | } | |
441 | 466 | else throw("Strict value is not equal to itself.") | |
442 | 467 | } | |
443 | 468 | ||
444 | 469 | ||
445 | 470 | ||
446 | - | @Callable( | |
447 | - | func cancelVote ( | |
448 | - | let | |
449 | - | let | |
450 | - | let | |
451 | - | let | |
452 | - | let | |
453 | - | let | |
454 | - | let | |
455 | - | let | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
471 | + | @Callable(bk) | |
472 | + | func cancelVote (G,H) = { | |
473 | + | let E = $Tuple2(G, H) | |
474 | + | let k = valueOrElse(getInteger(this, l), 0) | |
475 | + | let bA = aj(this, B(k)) | |
476 | + | let bu = aj(this, h) | |
477 | + | let bB = (bA + bu) | |
478 | + | let bC = getInteger(this, u) | |
479 | + | let bD = valueOrElse(getInteger(this, K(bk.caller, k)), 0) | |
480 | + | let bE = valueOrElse(getInteger(this, M(E, bk.caller, k)), 0) | |
481 | + | let bF = valueOrElse(getInteger(this, O(E, k)), 0) | |
482 | + | let bG = valueOrElse(getInteger(this, U(k)), 0) | |
483 | + | let bv = [if ((getBoolean(D(E)) != unit)) | |
459 | 484 | then true | |
460 | - | else | |
485 | + | else Z("invalid assets"), if ((bB > height)) | |
461 | 486 | then true | |
462 | - | else | |
487 | + | else Z("invalid height"), if ((bC == unit)) | |
463 | 488 | then true | |
464 | - | else | |
489 | + | else Z("finalization in progress"), if ((bE > 0)) | |
465 | 490 | then true | |
466 | - | else | |
467 | - | if (( | |
491 | + | else Z("no vote")] | |
492 | + | if ((bv == bv)) | |
468 | 493 | then { | |
469 | - | let | |
470 | - | let | |
471 | - | $Tuple2(([IntegerEntry( | |
494 | + | let bL = aM(E) | |
495 | + | let W = toString(bk.caller) | |
496 | + | $Tuple2(([IntegerEntry(K(bk.caller, k), max([(bD - bE), 0])), DeleteEntry(M(E, bk.caller, k)), IntegerEntry(O(E, k), (bF - bE)), IntegerEntry(U(k), (bG - bE))] ++ bc(bL, W)), unit) | |
472 | 497 | } | |
473 | 498 | else throw("Strict value is not equal to itself.") | |
474 | 499 | } | |
475 | 500 | ||
476 | 501 | ||
477 | 502 | ||
478 | - | @Callable( | |
479 | - | func setEpochLength ( | |
480 | - | let | |
503 | + | @Callable(bk) | |
504 | + | func setEpochLength (bN) = { | |
505 | + | let bv = [bm(bk), if ((bN > 0)) | |
481 | 506 | then true | |
482 | - | else | |
483 | - | if (( | |
484 | - | then $Tuple2([IntegerEntry( | |
507 | + | else Z("invalid epoch length")] | |
508 | + | if ((bv == bv)) | |
509 | + | then $Tuple2([IntegerEntry(i, bN)], unit) | |
485 | 510 | else throw("Strict value is not equal to itself.") | |
486 | 511 | } | |
487 | 512 | ||
488 | 513 | ||
489 | 514 | ||
490 | - | @Callable( | |
491 | - | func setMaxDepth ( | |
492 | - | let | |
515 | + | @Callable(bk) | |
516 | + | func setMaxDepth (bO) = { | |
517 | + | let bv = [bm(bk), if ((bO > 0)) | |
493 | 518 | then true | |
494 | - | else | |
495 | - | if (( | |
496 | - | then $Tuple2([IntegerEntry( | |
519 | + | else Z("invalid max depth")] | |
520 | + | if ((bv == bv)) | |
521 | + | then $Tuple2([IntegerEntry(m, bO)], unit) | |
497 | 522 | else throw("Strict value is not equal to itself.") | |
498 | 523 | } | |
499 | 524 | ||
500 | 525 | ||
501 | 526 | ||
502 | - | @Callable( | |
503 | - | func | |
504 | - | let | |
505 | - | if (( | |
527 | + | @Callable(bk) | |
528 | + | func processPoolBalanceINTERNAL (bP) = { | |
529 | + | let bQ = bn(bk) | |
530 | + | if ((bQ == bQ)) | |
506 | 531 | then { | |
507 | - | let bh = valueOrErrorMessage(addressFromString(R), S(("processVoteINTERNAL: invalid user address " + R))) | |
508 | - | let i = ae(this, j) | |
509 | - | let bK = (i - 1) | |
510 | - | let bn = ae(this, f) | |
511 | - | let bt = ae(this, y(i)) | |
512 | - | let bu = (bt + bn) | |
513 | - | let bL = ae(this, y(bK)) | |
514 | - | let bM = ae(this, h(bK)) | |
515 | - | let bN = (bL + bM) | |
516 | - | let bO = if ((bK >= 0)) | |
532 | + | let k = aj(this, l) | |
533 | + | let bR = (k - 1) | |
534 | + | let E = al(bP) | |
535 | + | let bS = E | |
536 | + | let G = bS._1 | |
537 | + | let H = bS._2 | |
538 | + | let aG = aw(G, H) | |
539 | + | let bT = { | |
540 | + | let ai = invoke(an, "checkBalance", [aG], nil) | |
541 | + | if ($isInstanceOf(ai, "Boolean")) | |
542 | + | then ai | |
543 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
544 | + | } | |
545 | + | let bU = !(valueOrElse(getBoolean(this, I(E, (bR - 1))), false)) | |
546 | + | let bV = if (!(bT)) | |
547 | + | then if (!(bU)) | |
548 | + | then { | |
549 | + | let bW = invoke(an, "deleteWxEmissionPoolLabel", [G, H], nil) | |
550 | + | if ((bW == bW)) | |
551 | + | then { | |
552 | + | let bX = invoke(an, "modifyWeight", [aG, 0], nil) | |
553 | + | if ((bX == bX)) | |
554 | + | then { | |
555 | + | let bY = valueOrErrorMessage(au(G, H), X("invalid assets"))._1 | |
556 | + | let bZ = 3 | |
557 | + | let ca = invoke(an, "managePool", [toString(bY), bZ], nil) | |
558 | + | if ((ca == ca)) | |
559 | + | then { | |
560 | + | let cb = ([DeleteEntry(D(E))] ++ bc(aL, ak(E))) | |
561 | + | ([IntegerEntry(S(E, bR), 0)] ++ cb) | |
562 | + | } | |
563 | + | else throw("Strict value is not equal to itself.") | |
564 | + | } | |
565 | + | else throw("Strict value is not equal to itself.") | |
566 | + | } | |
567 | + | else throw("Strict value is not equal to itself.") | |
568 | + | } | |
569 | + | else [BooleanEntry(I(E, bR), true)] | |
570 | + | else nil | |
571 | + | $Tuple2(bV, unit) | |
572 | + | } | |
573 | + | else throw("Strict value is not equal to itself.") | |
574 | + | } | |
575 | + | ||
576 | + | ||
577 | + | ||
578 | + | @Callable(bk) | |
579 | + | func processVoteINTERNAL (bP,W) = { | |
580 | + | let bQ = bn(bk) | |
581 | + | if ((bQ == bQ)) | |
582 | + | then { | |
583 | + | let bo = valueOrErrorMessage(addressFromString(W), X(("processVoteINTERNAL: invalid user address " + W))) | |
584 | + | let k = aj(this, l) | |
585 | + | let bR = (k - 1) | |
586 | + | let bu = aj(this, h) | |
587 | + | let bA = aj(this, B(k)) | |
588 | + | let bB = (bA + bu) | |
589 | + | let cc = aj(this, B(bR)) | |
590 | + | let cd = aj(this, j(bR)) | |
591 | + | let ce = (cc + cd) | |
592 | + | let cf = if ((bR >= 0)) | |
517 | 593 | then true | |
518 | - | else | |
519 | - | if (( | |
594 | + | else Z("processVoteINTERNAL: invalid previous epoch") | |
595 | + | if ((cf == cf)) | |
520 | 596 | then { | |
521 | - | let B = ag(bI) | |
522 | - | let bP = B | |
523 | - | let D = bP._1 | |
524 | - | let E = bP._2 | |
525 | - | let bD = aA(B) | |
526 | - | let bA = { | |
527 | - | let ad = invoke(this, "getUserGwxAmountAtHeight", [R, bu], nil) | |
528 | - | if ($isInstanceOf(ad, "Int")) | |
529 | - | then ad | |
530 | - | else throw(($getType(ad) + " couldn't be cast to Int")) | |
597 | + | let E = al(bP) | |
598 | + | let cg = E | |
599 | + | let G = cg._1 | |
600 | + | let H = cg._2 | |
601 | + | let bH = { | |
602 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [W, bB], nil) | |
603 | + | if ($isInstanceOf(ai, "Int")) | |
604 | + | then ai | |
605 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
531 | 606 | } | |
532 | - | let | |
533 | - | let | |
534 | - | if ($isInstanceOf( | |
535 | - | then | |
536 | - | else throw(($getType( | |
607 | + | let ch = { | |
608 | + | let ai = invoke(this, "getUserGwxAmountAtHeight", [W, ce], nil) | |
609 | + | if ($isInstanceOf(ai, "Int")) | |
610 | + | then ai | |
611 | + | else throw(($getType(ai) + " couldn't be cast to Int")) | |
537 | 612 | } | |
538 | - | let | |
539 | - | let | |
540 | - | let | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
544 | - | let | |
545 | - | let | |
546 | - | let | |
613 | + | let bG = valueOrElse(getInteger(U(k)), 0) | |
614 | + | let ci = valueOrElse(getInteger(O(E, k)), 0) | |
615 | + | let cj = valueOrErrorMessage(getInteger(M(E, bo, bR)), X((((("processVoteINTERNAL " + bP) + " ") + W) + ": no previous vote"))) | |
616 | + | let bD = valueOrElse(getInteger(this, K(bo, k)), 0) | |
617 | + | let R = aw(G, H) | |
618 | + | let ck = valueOrElse(getInteger(Q(R, bR)), 0) | |
619 | + | let bt = addressFromStringValue(ah(this, s)) | |
620 | + | let cl = valueOrElse(getInteger(bt, V(R, W)), 0) | |
621 | + | let cm = if ((cl == 0)) | |
547 | 622 | then nil | |
548 | - | else [IntegerEntry(L(M, bK), (bT + bS))] | |
549 | - | let az = ap(D, E) | |
550 | - | let bW = { | |
551 | - | let ad = invoke(ai, "checkBalance", [az], nil) | |
552 | - | if ($isInstanceOf(ad, "Boolean")) | |
553 | - | then ad | |
554 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
555 | - | } | |
556 | - | let bC = if ((bQ > 0)) | |
557 | - | then fraction(bS, bA, bQ) | |
623 | + | else [IntegerEntry(Q(R, bR), (ck + cj))] | |
624 | + | let aG = aw(G, H) | |
625 | + | let bJ = if ((ch > 0)) | |
626 | + | then fraction(cj, bH, ch) | |
558 | 627 | else 0 | |
559 | - | let bX = if (if (if ((bC > 0)) | |
560 | - | then bD | |
561 | - | else false) | |
562 | - | then bW | |
563 | - | else false) | |
564 | - | then [IntegerEntry(H(B, bh, i), bC), IntegerEntry(P(i), (bz + bC)), IntegerEntry(J(B, i), (bR + bC)), IntegerEntry(F(bh, i), (bw + bC))] | |
565 | - | else aV(aF(B), R) | |
566 | - | $Tuple2((bX ++ bV), unit) | |
628 | + | let bV = if ((bJ > 0)) | |
629 | + | then [IntegerEntry(M(E, bo, k), bJ), IntegerEntry(U(k), (bG + bJ)), IntegerEntry(O(E, k), (ci + bJ)), IntegerEntry(K(bo, k), (bD + bJ))] | |
630 | + | else bc(aM(E), W) | |
631 | + | $Tuple2((bV ++ cm), unit) | |
567 | 632 | } | |
568 | 633 | else throw("Strict value is not equal to itself.") | |
569 | 634 | } | |
570 | 635 | else throw("Strict value is not equal to itself.") | |
571 | 636 | } | |
572 | 637 | ||
573 | 638 | ||
574 | 639 | ||
575 | - | @Callable( | |
576 | - | func processPoolINTERNAL ( | |
577 | - | let | |
578 | - | if (( | |
640 | + | @Callable(bk) | |
641 | + | func processPoolINTERNAL (bP,cn) = { | |
642 | + | let bQ = bn(bk) | |
643 | + | if ((bQ == bQ)) | |
579 | 644 | then { | |
580 | - | let | |
581 | - | let | |
582 | - | if ( | |
583 | - | then | |
584 | - | else ( | |
645 | + | let co = { | |
646 | + | let cp = aj(this, l) | |
647 | + | if (cn) | |
648 | + | then cp | |
649 | + | else (cp - 1) | |
585 | 650 | } | |
586 | - | let | |
651 | + | let cf = if ((co >= 0)) | |
587 | 652 | then true | |
588 | - | else | |
589 | - | if (( | |
653 | + | else Z("processPoolINTERNAL: invalid target epoch") | |
654 | + | if ((cf == cf)) | |
590 | 655 | then { | |
591 | - | let | |
592 | - | let | |
593 | - | let | |
594 | - | let | |
595 | - | let | |
596 | - | let | |
597 | - | let | |
598 | - | let | |
599 | - | if ($isInstanceOf( | |
600 | - | then | |
601 | - | else throw(($getType( | |
656 | + | let E = al(bP) | |
657 | + | let cq = E | |
658 | + | let G = cq._1 | |
659 | + | let H = cq._2 | |
660 | + | let bt = addressFromStringValue(ah(this, s)) | |
661 | + | let aG = aw(G, H) | |
662 | + | let cr = { | |
663 | + | let ai = invoke(bt, "usersListTraversal", [aG], nil) | |
664 | + | if ($isInstanceOf(ai, "Boolean")) | |
665 | + | then ai | |
666 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
602 | 667 | } | |
603 | - | if (( | |
604 | - | then if ( | |
668 | + | if ((cr == cr)) | |
669 | + | then if (cr) | |
605 | 670 | then $Tuple2(nil, true) | |
606 | 671 | else { | |
607 | - | let cd = addressFromStringValue(valueOrElse(getString(this, q), "invalid assets store contract")) | |
608 | - | let bD = aA(B) | |
609 | - | let bW = { | |
610 | - | let ad = invoke(ai, "checkBalance", [az], nil) | |
611 | - | if ($isInstanceOf(ad, "Boolean")) | |
612 | - | then ad | |
613 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
614 | - | } | |
615 | - | let ce = { | |
616 | - | let ad = invoke(cd, "isVerifiedREADONLY", [D], nil) | |
617 | - | if ($isInstanceOf(ad, "Boolean")) | |
618 | - | then ad | |
619 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
620 | - | } | |
621 | - | let cf = { | |
622 | - | let ad = invoke(cd, "isVerifiedREADONLY", [E], nil) | |
623 | - | if ($isInstanceOf(ad, "Boolean")) | |
624 | - | then ad | |
625 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
626 | - | } | |
627 | - | let cg = if (if (if (if (!(bD)) | |
628 | - | then bW | |
629 | - | else false) | |
630 | - | then ce | |
631 | - | else false) | |
632 | - | then cf | |
633 | - | else false) | |
634 | - | then invoke(ai, "setWxEmissionPoolLabel", [D, E], nil) | |
635 | - | else unit | |
636 | - | if ((cg == cg)) | |
637 | - | then { | |
638 | - | let bz = valueOrElse(getInteger(this, P(bZ)), 0) | |
639 | - | let bR = valueOrElse(getInteger(this, J(B, bZ)), 0) | |
640 | - | let ch = if (if (if ((bz == 0)) | |
641 | - | then true | |
642 | - | else !(bD)) | |
643 | - | then true | |
644 | - | else !(bW)) | |
645 | - | then 0 | |
646 | - | else fraction(bR, b, bz) | |
647 | - | let ci = invoke(ai, "modifyWeight", [az, ch], nil) | |
648 | - | if ((ci == ci)) | |
649 | - | then $Tuple2([IntegerEntry(N(B, bZ), ch)], false) | |
650 | - | else throw("Strict value is not equal to itself.") | |
651 | - | } | |
672 | + | let cs = addressFromStringValue(valueOrErrorMessage(getString(an, t), "invalid assets store contract")) | |
673 | + | let bG = valueOrElse(getInteger(this, U(co)), 0) | |
674 | + | let ci = valueOrElse(getInteger(this, O(E, co)), 0) | |
675 | + | let ct = if ((bG == 0)) | |
676 | + | then 0 | |
677 | + | else fraction(ci, b, bG) | |
678 | + | let bX = invoke(an, "modifyWeight", [aG, ct], nil) | |
679 | + | if ((bX == bX)) | |
680 | + | then $Tuple2([IntegerEntry(S(E, co), ct)], false) | |
652 | 681 | else throw("Strict value is not equal to itself.") | |
653 | 682 | } | |
654 | 683 | else throw("Strict value is not equal to itself.") | |
655 | 684 | } | |
656 | 685 | else throw("Strict value is not equal to itself.") | |
657 | 686 | } | |
658 | 687 | else throw("Strict value is not equal to itself.") | |
659 | 688 | } | |
660 | 689 | ||
661 | 690 | ||
662 | 691 | ||
663 | - | @Callable( | |
692 | + | @Callable(bk) | |
664 | 693 | func finalizeHelper () = { | |
665 | - | let | |
666 | - | let | |
667 | - | let | |
668 | - | let | |
669 | - | let | |
670 | - | let | |
671 | - | let | |
672 | - | if (if (if ((height >= | |
673 | - | then ( | |
694 | + | let cn = valueOrElse(getBoolean(A), false) | |
695 | + | let k = valueOrElse(getInteger(this, l), 0) | |
696 | + | let cu = (k - 1) | |
697 | + | let bA = aj(this, B(k)) | |
698 | + | let bu = aj(this, h) | |
699 | + | let bB = (bA + bu) | |
700 | + | let bC = getInteger(this, u) | |
701 | + | if (if (if ((height >= bB)) | |
702 | + | then (bC == unit) | |
674 | 703 | else false) | |
675 | - | then !( | |
704 | + | then !(cn) | |
676 | 705 | else false) | |
677 | 706 | then { | |
678 | - | let | |
679 | - | let | |
680 | - | let | |
681 | - | let | |
682 | - | if ($isInstanceOf( | |
707 | + | let cv = (k + 1) | |
708 | + | let cw = getInteger(this, i) | |
709 | + | let cx = { | |
710 | + | let ae = cw | |
711 | + | if ($isInstanceOf(ae, "Int")) | |
683 | 712 | then { | |
684 | - | let | |
685 | - | [IntegerEntry( | |
713 | + | let bN = ae | |
714 | + | [IntegerEntry(h, bN), DeleteEntry(i)] | |
686 | 715 | } | |
687 | - | else if ($isInstanceOf( | |
716 | + | else if ($isInstanceOf(ae, "Unit")) | |
688 | 717 | then nil | |
689 | 718 | else throw("Match error") | |
690 | 719 | } | |
691 | - | $Tuple2(([IntegerEntry( | |
720 | + | $Tuple2(([IntegerEntry(B(cv), height), IntegerEntry(x, height), IntegerEntry(l, cv), IntegerEntry(u, d), IntegerEntry(j(k), bu)] ++ cx), true) | |
692 | 721 | } | |
693 | - | else if (if ( | |
694 | - | then ( | |
722 | + | else if (if (cn) | |
723 | + | then (bC == unit) | |
695 | 724 | else false) | |
696 | - | then $Tuple2([IntegerEntry( | |
697 | - | else if (( | |
725 | + | then $Tuple2([IntegerEntry(u, f)], true) | |
726 | + | else if ((bC == unit)) | |
698 | 727 | then $Tuple2(nil, false) | |
699 | - | else if (( | |
728 | + | else if ((bC == d)) | |
700 | 729 | then { | |
701 | - | let cn = getString(s) | |
702 | - | let co = getString(t) | |
703 | - | let Z = cn | |
704 | - | if ($isInstanceOf(Z, "Unit")) | |
730 | + | let cy = getString(v) | |
731 | + | let ae = cy | |
732 | + | if ($isInstanceOf(ae, "Unit")) | |
705 | 733 | then { | |
706 | - | let | |
707 | - | if ($isInstanceOf( | |
708 | - | then $Tuple2([IntegerEntry( | |
709 | - | else if ($isInstanceOf( | |
734 | + | let cz = getString(aO(aL)) | |
735 | + | if ($isInstanceOf(cz, "Unit")) | |
736 | + | then $Tuple2([IntegerEntry(u, e), DeleteEntry(v)], true) | |
737 | + | else if ($isInstanceOf(cz, "String")) | |
710 | 738 | then { | |
711 | - | let | |
712 | - | $Tuple2([StringEntry( | |
739 | + | let cA = cz | |
740 | + | $Tuple2([StringEntry(v, cA)], true) | |
713 | 741 | } | |
714 | 742 | else throw("Match error") | |
715 | 743 | } | |
716 | - | else if ($isInstanceOf( | |
744 | + | else if ($isInstanceOf(ae, "String")) | |
717 | 745 | then { | |
718 | - | let bI = Z | |
719 | - | let B = ag(bI) | |
720 | - | let cr = { | |
721 | - | let cp = co | |
722 | - | if ($isInstanceOf(cp, "Unit")) | |
723 | - | then getString(aH(aF(B))) | |
724 | - | else if ($isInstanceOf(cp, "String")) | |
746 | + | let bP = ae | |
747 | + | let cB = getString(aU(aL, bP)) | |
748 | + | if ((cB == cB)) | |
749 | + | then { | |
750 | + | let cr = invoke(this, "processPoolBalanceINTERNAL", [bP], nil) | |
751 | + | if ((cr == cr)) | |
725 | 752 | then { | |
726 | - | let cs = cp | |
727 | - | let ct = getString(aN(aF(B), cs)) | |
728 | - | if ((ct == ct)) | |
753 | + | let cz = cB | |
754 | + | if ($isInstanceOf(cz, "Unit")) | |
755 | + | then $Tuple2([IntegerEntry(u, e), DeleteEntry(v)], true) | |
756 | + | else if ($isInstanceOf(cz, "String")) | |
757 | + | then { | |
758 | + | let cA = cz | |
759 | + | $Tuple2([StringEntry(v, cA)], true) | |
760 | + | } | |
761 | + | else throw("Match error") | |
762 | + | } | |
763 | + | else throw("Strict value is not equal to itself.") | |
764 | + | } | |
765 | + | else throw("Strict value is not equal to itself.") | |
766 | + | } | |
767 | + | else throw("Match error") | |
768 | + | } | |
769 | + | else if ((bC == e)) | |
770 | + | then { | |
771 | + | let cy = getString(v) | |
772 | + | let cC = getString(w) | |
773 | + | let ae = cy | |
774 | + | if ($isInstanceOf(ae, "Unit")) | |
775 | + | then { | |
776 | + | let cz = getString(aO(aL)) | |
777 | + | if ($isInstanceOf(cz, "Unit")) | |
778 | + | then $Tuple2([IntegerEntry(u, f), DeleteEntry(v), DeleteEntry(w)], true) | |
779 | + | else if ($isInstanceOf(cz, "String")) | |
780 | + | then { | |
781 | + | let cD = cz | |
782 | + | $Tuple2([StringEntry(v, cD)], true) | |
783 | + | } | |
784 | + | else throw("Match error") | |
785 | + | } | |
786 | + | else if ($isInstanceOf(ae, "String")) | |
787 | + | then { | |
788 | + | let bP = ae | |
789 | + | let E = al(bP) | |
790 | + | let cE = { | |
791 | + | let cz = cC | |
792 | + | if ($isInstanceOf(cz, "Unit")) | |
793 | + | then getString(aO(aM(E))) | |
794 | + | else if ($isInstanceOf(cz, "String")) | |
795 | + | then { | |
796 | + | let cF = cz | |
797 | + | let cG = getString(aU(aM(E), cF)) | |
798 | + | if ((cG == cG)) | |
799 | + | then { | |
800 | + | let cH = invoke(this, "processVoteINTERNAL", [bP, cF], nil) | |
801 | + | if ((cH == cH)) | |
802 | + | then cG | |
803 | + | else throw("Strict value is not equal to itself.") | |
804 | + | } | |
805 | + | else throw("Strict value is not equal to itself.") | |
806 | + | } | |
807 | + | else throw("Match error") | |
808 | + | } | |
809 | + | let cz = cE | |
810 | + | if ($isInstanceOf(cz, "Unit")) | |
811 | + | then { | |
812 | + | let cB = getString(aU(aL, bP)) | |
813 | + | let cI = cB | |
814 | + | if ($isInstanceOf(cI, "Unit")) | |
815 | + | then $Tuple2([IntegerEntry(u, f), DeleteEntry(v), DeleteEntry(w)], true) | |
816 | + | else if ($isInstanceOf(cI, "String")) | |
729 | 817 | then { | |
730 | - | let cu = invoke(this, "processVoteINTERNAL", [bI, cs], nil) | |
731 | - | if ((cu == cu)) | |
732 | - | then ct | |
733 | - | else throw("Strict value is not equal to itself.") | |
818 | + | let bg = cI | |
819 | + | $Tuple2([StringEntry(v, bg), DeleteEntry(w)], true) | |
734 | 820 | } | |
735 | - | else throw("Strict value is not equal to itself.") | |
821 | + | else throw("Match error") | |
822 | + | } | |
823 | + | else if ($isInstanceOf(cz, "String")) | |
824 | + | then { | |
825 | + | let cJ = cz | |
826 | + | $Tuple2([StringEntry(w, cJ)], true) | |
736 | 827 | } | |
737 | 828 | else throw("Match error") | |
738 | 829 | } | |
739 | - | let cp = cr | |
740 | - | if ($isInstanceOf(cp, "Unit")) | |
830 | + | else throw("Match error") | |
831 | + | } | |
832 | + | else if ((bC == f)) | |
833 | + | then { | |
834 | + | let cy = getString(v) | |
835 | + | let ae = cy | |
836 | + | if ($isInstanceOf(ae, "Unit")) | |
837 | + | then { | |
838 | + | let cz = getString(aO(aL)) | |
839 | + | if ($isInstanceOf(cz, "Unit")) | |
840 | + | then { | |
841 | + | let bV = if (cn) | |
842 | + | then [DeleteEntry(u), DeleteEntry(A)] | |
843 | + | else [DeleteEntry(u), BooleanEntry(C(cu), true), IntegerEntry(y, k), IntegerEntry(z, bA)] | |
844 | + | let cK = aJ() | |
845 | + | if ((cK == cK)) | |
846 | + | then $Tuple2(bV, true) | |
847 | + | else throw("Strict value is not equal to itself.") | |
848 | + | } | |
849 | + | else if ($isInstanceOf(cz, "String")) | |
850 | + | then { | |
851 | + | let cA = cz | |
852 | + | $Tuple2([StringEntry(v, cA)], true) | |
853 | + | } | |
854 | + | else throw("Match error") | |
855 | + | } | |
856 | + | else if ($isInstanceOf(ae, "String")) | |
741 | 857 | then { | |
742 | - | let cv = getString(aN(aE, bI)) | |
743 | - | let cw = cv | |
744 | - | if ($isInstanceOf(cw, "Unit")) | |
745 | - | then $Tuple2([IntegerEntry(r, e), DeleteEntry(s), DeleteEntry(t)], true) | |
746 | - | else if ($isInstanceOf(cw, "String")) | |
747 | - | then { | |
748 | - | let aZ = cw | |
749 | - | $Tuple2([StringEntry(s, aZ), DeleteEntry(t)], true) | |
858 | + | let bP = ae | |
859 | + | let cB = getString(aU(aL, bP)) | |
860 | + | if ((cB == cB)) | |
861 | + | then { | |
862 | + | let cr = { | |
863 | + | let ai = invoke(this, "processPoolINTERNAL", [bP, cn], nil) | |
864 | + | if ($isInstanceOf(ai, "Boolean")) | |
865 | + | then ai | |
866 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
750 | 867 | } | |
751 | - | else throw("Match error") | |
752 | - | } | |
753 | - | else if ($isInstanceOf(cp, "String")) | |
754 | - | then { | |
755 | - | let cx = cp | |
756 | - | $Tuple2([StringEntry(t, cx)], true) | |
757 | - | } | |
758 | - | else throw("Match error") | |
759 | - | } | |
760 | - | else throw("Match error") | |
761 | - | } | |
762 | - | else if ((bv == e)) | |
763 | - | then { | |
764 | - | let cn = getString(s) | |
765 | - | let Z = cn | |
766 | - | if ($isInstanceOf(Z, "Unit")) | |
767 | - | then { | |
768 | - | let cp = getString(aH(aE)) | |
769 | - | if ($isInstanceOf(cp, "Unit")) | |
770 | - | then { | |
771 | - | let bX = if (bY) | |
772 | - | then [DeleteEntry(r), DeleteEntry(x)] | |
773 | - | else [DeleteEntry(r), BooleanEntry(z(cj), true), IntegerEntry(v, i), IntegerEntry(w, bt)] | |
774 | - | let cy = aC() | |
775 | - | if ((cy == cy)) | |
776 | - | then $Tuple2(bX, true) | |
868 | + | if ((cr == cr)) | |
869 | + | then if (cr) | |
870 | + | then $Tuple2(nil, true) | |
871 | + | else { | |
872 | + | let cz = cB | |
873 | + | if ($isInstanceOf(cz, "Unit")) | |
874 | + | then { | |
875 | + | let bV = if (cn) | |
876 | + | then [DeleteEntry(u), DeleteEntry(A), DeleteEntry(v)] | |
877 | + | else [DeleteEntry(u), BooleanEntry(C(cu), true), IntegerEntry(y, k), IntegerEntry(z, bA), DeleteEntry(v)] | |
878 | + | let cK = aJ() | |
879 | + | if ((cK == cK)) | |
880 | + | then $Tuple2(bV, true) | |
881 | + | else throw("Strict value is not equal to itself.") | |
882 | + | } | |
883 | + | else if ($isInstanceOf(cz, "String")) | |
884 | + | then { | |
885 | + | let cA = cz | |
886 | + | $Tuple2([StringEntry(v, cA)], true) | |
887 | + | } | |
888 | + | else throw("Match error") | |
889 | + | } | |
890 | + | else throw("Strict value is not equal to itself.") | |
891 | + | } | |
777 | 892 | else throw("Strict value is not equal to itself.") | |
778 | 893 | } | |
779 | - | else if ($isInstanceOf(cp, "String")) | |
780 | - | then { | |
781 | - | let cz = cp | |
782 | - | $Tuple2([StringEntry(s, cz)], true) | |
783 | - | } | |
784 | - | else throw("Match error") | |
785 | - | } | |
786 | - | else if ($isInstanceOf(Z, "String")) | |
787 | - | then { | |
788 | - | let bI = Z | |
789 | - | let cv = getString(aN(aE, bI)) | |
790 | - | if ((cv == cv)) | |
791 | - | then { | |
792 | - | let cc = { | |
793 | - | let ad = invoke(this, "processPoolINTERNAL", [bI, bY], nil) | |
794 | - | if ($isInstanceOf(ad, "Boolean")) | |
795 | - | then ad | |
796 | - | else throw(($getType(ad) + " couldn't be cast to Boolean")) | |
797 | - | } | |
798 | - | if ((cc == cc)) | |
799 | - | then if (cc) | |
800 | - | then $Tuple2(nil, true) | |
801 | - | else { | |
802 | - | let cp = cv | |
803 | - | if ($isInstanceOf(cp, "Unit")) | |
804 | - | then { | |
805 | - | let bX = if (bY) | |
806 | - | then [DeleteEntry(r), DeleteEntry(x), DeleteEntry(s)] | |
807 | - | else [DeleteEntry(r), BooleanEntry(z(cj), true), IntegerEntry(v, i), IntegerEntry(w, bt), DeleteEntry(s)] | |
808 | - | let cy = aC() | |
809 | - | if ((cy == cy)) | |
810 | - | then $Tuple2(bX, true) | |
811 | - | else throw("Strict value is not equal to itself.") | |
812 | - | } | |
813 | - | else if ($isInstanceOf(cp, "String")) | |
814 | - | then { | |
815 | - | let cz = cp | |
816 | - | $Tuple2([StringEntry(s, cz)], true) | |
817 | - | } | |
818 | - | else throw("Match error") | |
819 | - | } | |
820 | - | else throw("Strict value is not equal to itself.") | |
821 | - | } | |
822 | - | else throw("Strict value is not equal to itself.") | |
823 | - | } | |
824 | - | else throw("Match error") | |
825 | - | } | |
826 | - | else U("finalization is broken") | |
894 | + | else throw("Match error") | |
895 | + | } | |
896 | + | else Z("finalization is broken") | |
827 | 897 | } | |
828 | 898 | ||
829 | 899 | ||
830 | 900 | ||
831 | - | @Callable( | |
832 | - | func finalizeWrapper ( | |
833 | - | let | |
834 | - | let | |
835 | - | let | |
836 | - | if ($isInstanceOf( | |
837 | - | then | |
838 | - | else throw(($getType( | |
901 | + | @Callable(bk) | |
902 | + | func finalizeWrapper (cL) = { | |
903 | + | let cM = addressFromStringValue(getStringValue(this, p)) | |
904 | + | let cN = { | |
905 | + | let ai = invoke(this, "finalizeHelper", nil, nil) | |
906 | + | if ($isInstanceOf(ai, "Boolean")) | |
907 | + | then ai | |
908 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
839 | 909 | } | |
840 | - | if (( | |
841 | - | then if (!( | |
842 | - | then if (( | |
843 | - | then | |
910 | + | if ((cN == cN)) | |
911 | + | then if (!(cN)) | |
912 | + | then if ((cL == 0)) | |
913 | + | then Z("Current voting is not over yet") | |
844 | 914 | else { | |
845 | - | let | |
846 | - | if (( | |
915 | + | let cO = invoke(cM, "finalize", nil, nil) | |
916 | + | if ((cO == cO)) | |
847 | 917 | then $Tuple2(nil, unit) | |
848 | 918 | else throw("Strict value is not equal to itself.") | |
849 | 919 | } | |
850 | 920 | else { | |
851 | - | let | |
852 | - | if (( | |
921 | + | let cP = valueOrElse(getInteger(this, m), c) | |
922 | + | if ((cP > cL)) | |
853 | 923 | then { | |
854 | - | let | |
855 | - | if (( | |
924 | + | let cO = invoke(this, "finalizeWrapper", [(cL + 1)], nil) | |
925 | + | if ((cO == cO)) | |
856 | 926 | then $Tuple2(nil, unit) | |
857 | 927 | else throw("Strict value is not equal to itself.") | |
858 | 928 | } | |
859 | 929 | else $Tuple2(nil, unit) | |
860 | 930 | } | |
861 | 931 | else throw("Strict value is not equal to itself.") | |
862 | 932 | } | |
863 | 933 | ||
864 | 934 | ||
865 | 935 | ||
866 | - | @Callable( | |
936 | + | @Callable(bk) | |
867 | 937 | func finalize () = { | |
868 | - | let | |
869 | - | if (( | |
938 | + | let cO = invoke(this, "finalizeWrapper", [0], nil) | |
939 | + | if ((cO == cO)) | |
870 | 940 | then $Tuple2(nil, unit) | |
871 | 941 | else throw("Strict value is not equal to itself.") | |
872 | 942 | } | |
873 | 943 | ||
874 | 944 | ||
875 | 945 | ||
876 | - | @Callable( | |
877 | - | func containsNodeREADONLY ( | |
946 | + | @Callable(bk) | |
947 | + | func containsNodeREADONLY (aP,aT) = $Tuple2(nil, aV(aP, aT)) | |
878 | 948 | ||
879 | 949 | ||
880 | 950 | ||
881 | - | @Callable( | |
882 | - | func insertNode ( | |
883 | - | let | |
884 | - | if (( | |
885 | - | then $Tuple2( | |
951 | + | @Callable(bk) | |
952 | + | func insertNode (aP,aT) = { | |
953 | + | let bQ = bm(bk) | |
954 | + | if ((bQ == bQ)) | |
955 | + | then $Tuple2(aZ(aP, aT), unit) | |
886 | 956 | else throw("Strict value is not equal to itself.") | |
887 | 957 | } | |
888 | 958 | ||
889 | 959 | ||
890 | 960 | ||
891 | - | @Callable( | |
892 | - | func deleteNode ( | |
893 | - | let | |
894 | - | if (( | |
895 | - | then $Tuple2( | |
961 | + | @Callable(bk) | |
962 | + | func deleteNode (aP,aT) = { | |
963 | + | let bQ = bm(bk) | |
964 | + | if ((bQ == bQ)) | |
965 | + | then $Tuple2(bc(aP, aT), unit) | |
896 | 966 | else throw("Strict value is not equal to itself.") | |
897 | 967 | } | |
898 | 968 | ||
899 | 969 | ||
900 | 970 | ||
901 | - | @Callable( | |
971 | + | @Callable(bk) | |
902 | 972 | func isFinalizationInProgress () = { | |
903 | - | let | |
904 | - | let | |
905 | - | $Tuple2(nil, | |
973 | + | let bC = getInteger(this, u) | |
974 | + | let cQ = (bC != unit) | |
975 | + | $Tuple2(nil, cQ) | |
906 | 976 | } | |
907 | 977 | ||
908 | 978 | ||
909 | 979 | ||
910 | - | @Callable( | |
911 | - | func deletePool ( | |
912 | - | let | |
980 | + | @Callable(bk) | |
981 | + | func deletePool (G,H) = { | |
982 | + | let bQ = if (if ((bk.caller == an)) | |
913 | 983 | then true | |
914 | - | else | |
984 | + | else bm(bk)) | |
915 | 985 | then true | |
916 | - | else | |
917 | - | if (( | |
986 | + | else Z("Permission denied") | |
987 | + | if ((bQ == bQ)) | |
918 | 988 | then { | |
919 | - | let | |
920 | - | let | |
921 | - | let | |
922 | - | let | |
923 | - | then | |
989 | + | let aP = "pools" | |
990 | + | let E = $Tuple2(G, H) | |
991 | + | let aT = makeString([G, H], a) | |
992 | + | let bV = if (aV(aP, aT)) | |
993 | + | then bc(aP, aT) | |
924 | 994 | else nil | |
925 | - | ([DeleteEntry( | |
995 | + | ([DeleteEntry(D(E))] ++ bV) | |
926 | 996 | } | |
927 | 997 | else throw("Strict value is not equal to itself.") | |
928 | 998 | } | |
929 | 999 | ||
930 | 1000 | ||
931 | - | @Verifier(cG) | |
932 | - | func cH () = { | |
933 | - | let cI = { | |
934 | - | let Z = ba() | |
935 | - | if ($isInstanceOf(Z, "ByteVector")) | |
1001 | + | ||
1002 | + | @Callable(bk) | |
1003 | + | func resume (G,H) = { | |
1004 | + | let aG = aw(G, H) | |
1005 | + | let cR = { | |
1006 | + | let ai = invoke(an, "checkBalance", [aG], nil) | |
1007 | + | if ($isInstanceOf(ai, "Boolean")) | |
1008 | + | then ai | |
1009 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1010 | + | } | |
1011 | + | let cS = bk.payments[0] | |
1012 | + | let cs = addressFromStringValue(getStringValue(this, t)) | |
1013 | + | let cT = "%s__config" | |
1014 | + | let cU = 1 | |
1015 | + | let bs = addressFromStringValue(ah(this, r)) | |
1016 | + | let cV = fromBase58String(split(getStringValue(bs, cT), a)[cU]) | |
1017 | + | let cW = { | |
1018 | + | let ai = invoke(cs, "isVerifiedREADONLY", [G], nil) | |
1019 | + | if ($isInstanceOf(ai, "Boolean")) | |
1020 | + | then ai | |
1021 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1022 | + | } | |
1023 | + | let cX = { | |
1024 | + | let ai = invoke(cs, "isVerifiedREADONLY", [H], nil) | |
1025 | + | if ($isInstanceOf(ai, "Boolean")) | |
1026 | + | then ai | |
1027 | + | else throw(($getType(ai) + " couldn't be cast to Boolean")) | |
1028 | + | } | |
1029 | + | let cY = valueOrElse(getInteger(this, n), g) | |
1030 | + | let bv = [if (cR) | |
1031 | + | then true | |
1032 | + | else Z("insufficient balances"), if ((size(bk.payments) == 1)) | |
1033 | + | then true | |
1034 | + | else Z("1 payment is required"), if ((cS.assetId == cV)) | |
1035 | + | then true | |
1036 | + | else Z("invalid payment asset id"), if ((cS.amount == cY)) | |
1037 | + | then true | |
1038 | + | else Z("invalid payment amount"), if (if (cW) | |
1039 | + | then cX | |
1040 | + | else false) | |
1041 | + | then true | |
1042 | + | else Z("both assets should be verified")] | |
1043 | + | if ((bv == bv)) | |
1044 | + | then { | |
1045 | + | let E = $Tuple2(G, H) | |
1046 | + | let bw = ([BooleanEntry(D(E), true)] ++ aZ(aL, ak(E))) | |
1047 | + | $Tuple2(bw, unit) | |
1048 | + | } | |
1049 | + | else throw("Strict value is not equal to itself.") | |
1050 | + | } | |
1051 | + | ||
1052 | + | ||
1053 | + | @Verifier(cZ) | |
1054 | + | func da () = { | |
1055 | + | let db = { | |
1056 | + | let ae = bh() | |
1057 | + | if ($isInstanceOf(ae, "ByteVector")) | |
936 | 1058 | then { | |
937 | - | let | |
938 | - | | |
1059 | + | let bl = ae | |
1060 | + | bl | |
939 | 1061 | } | |
940 | - | else if ($isInstanceOf( | |
941 | - | then | |
1062 | + | else if ($isInstanceOf(ae, "Unit")) | |
1063 | + | then cZ.senderPublicKey | |
942 | 1064 | else throw("Match error") | |
943 | 1065 | } | |
944 | - | sigVerify( | |
1066 | + | sigVerify(cZ.bodyBytes, cZ.proofs[0], db) | |
945 | 1067 | } | |
946 | 1068 |
github/deemru/w8io/fabc49c 232.31 ms ◑