tx · AC7Jm9xa3KHRUqBZFz8T9E3o25ALBL5D7b8S68CyKxoi 3NC9boevS259eTsMAkFAxCPorzK4Z9bpWje: -0.01800000 Waves 2023.01.31 13:17 [2428994] smart account 3NC9boevS259eTsMAkFAxCPorzK4Z9bpWje > SELF 0.00000000 Waves
{ "type": 13, "id": "AC7Jm9xa3KHRUqBZFz8T9E3o25ALBL5D7b8S68CyKxoi", "fee": 1800000, "feeAssetId": null, "timestamp": 1675160261721, "version": 2, "chainId": 84, "sender": "3NC9boevS259eTsMAkFAxCPorzK4Z9bpWje", "senderPublicKey": "515tSAyMUbAb8kKjcpGDpqALGfCgcwfWmWKKkcBKTcGB", "proofs": [ "66STey1wpXaxSHvdKqBGn8hh1JPZ2x3wsexCdTU57urBrPjtYzqEqhuVeVBnQstaS7dmGJDCj3bFt4Vo5mQXcLmq" ], "script": "base64:AAIFAAAAAAAAACEIAhIAEgASAwoBCBIDCgEIEgMKAQESABIDCgEIEgMKAQgAAAADAAAAABREYXBwX0FkZHJlc3NfcHViX2tleQEAAAAgq4kJ/Yx/hxwE0cwMFuJmegviyQmGySeZGqn46Eb83C8AAAAAGW9yYWNsZV9jb250cm9sbGVyX2FkZHJlc3MJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEFAAAAFERhcHBfQWRkcmVzc19wdWJfa2V5AAAAAAtVU0RUQXNzZXRJRAEAAAAAAAAACAAAAAFpAQAAAA9wbGFjZW9wdGlvbkNhbGwAAAAABAAAAA1jYWxsZXJhZGRyZXNzCQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMEAAAADWlmQmxhY2tsaXN0ZWQJAAQdAAAAAgUAAAAEdGhpcwkAASwAAAACAgAAABFhZGRyX0JMQUNLTElTVEVEXwUAAAANY2FsbGVyYWRkcmVzcwQAAAAScmVhZF9vcmFjbGVfc3RhdHVzCQEAAAARQGV4dHJOYXRpdmUoMTA1MykAAAACBQAAAAR0aGlzAgAAAA1vcmFjbGVfc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Zpb3VzQmxhY2tMaXN0QWRkcmVzcwAAAAAAAAAAAQMJAQAAAAIhPQAAAAIIBQAAAAFpAAAABmNhbGxlcgUAAAAZb3JhY2xlX2NvbnRyb2xsZXJfYWRkcmVzcwkAAAIAAAABCQABLAAAAAIJAAEsAAAAAgIAAAAlVGhpcyBBZGRyZXNzIGlzIG5vdCBBdXRob3JpemVkLiBPbmx5IAkABCUAAAABBQAAABlvcmFjbGVfY29udHJvbGxlcl9hZGRyZXNzAgAAACIgaXMgQXV0aG9yaXplZCBBZGRyZXNzIHRvIFNpZ24gaXQuAwkAAAAAAAACBQAAAA1pZkJsYWNrbGlzdGVkAgAAAANZZXMJAARMAAAAAgkBAAAAC0RlbGV0ZUVudHJ5AAAAAQkAASwAAAACAgAAABFhZGRyX0JMQUNLTElTVEVEXwUAAAALVXNlckFkZHJlc3MJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAAGlRvdGFsX0JsYWNrX0xpc3RlZF9BZGRyZXNzBQAAABVUb3RhbEJsYWNrTGlzdEFkZHJlc3MFAAAAA25pbAkAAAIAAAABAgAAACZBZGRyZXNzIGlzIG5vdCBhdmFpbGFibGUgaW4gQmxhY2tsaXN0LgAAAAEAAAACdHgBAAAABnZlcmlmeQAAAAAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5XxDwlg==", "height": 2428994, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5dZVH1MQaqe7iH3huU6zkxfcRkaxQzSdj3pzAUyvwUP2 Next: B6eZquZXJPeFD7ZzkudGkJGUV6hStMzCxsFt5pJgaXuG Diff:
Old | New | Differences | |
---|---|---|---|
41 | 41 | 0 | |
42 | 42 | } | |
43 | 43 | let TotalUserCall = (PreviousUserCall + 1) | |
44 | + | let PreviousUserCallinSpecificCounter = match getInteger(this, ((calleraddress + "_Total_Calls_") + toString(read_OptionCounterID))) { | |
45 | + | case a: Int => | |
46 | + | a | |
47 | + | case _ => | |
48 | + | 0 | |
49 | + | } | |
50 | + | let TotalUserCallinSpecificCounter = (PreviousUserCallinSpecificCounter + 1) | |
44 | 51 | if ((checkblockgap > 2)) | |
45 | 52 | then throw("Something Wrong with Oracle or Height is not matched.") | |
46 | 53 | else if ((read_oracle_status == "Close")) | |
47 | 54 | then throw("Oracle is closed. Wait Until Oracle is Turned On.") | |
48 | 55 | else if ((ifBlacklisted == "Yes")) | |
49 | 56 | then throw((calleraddress + " Address is Blacklisted. Please contact Admin to Whitelist it.")) | |
50 | - | else [StringEntry(((("Call_" + calleraddress) + "_") + toString(TotalUserCall)), price), StringEntry(((("Call_Start_End_" + calleraddress) + "_") + toString(TotalUserCall)), ((toString(read_OptionCounterID) + "_") + toString(OptionExpireCounterID))), IntegerEntry("Total_Calls", TotalCall), IntegerEntry(("Total_Calls_" + toString(read_OptionCounterID)), TotalCallinSpecificCounter), IntegerEntry((calleraddress + "_Total_Calls"), TotalUserCall)] | |
57 | + | else [StringEntry(((("Call_" + calleraddress) + "_") + toString(TotalUserCall)), price), StringEntry(((("Call_Start_End_" + calleraddress) + "_") + toString(TotalUserCall)), ((toString(read_OptionCounterID) + "_") + toString(OptionExpireCounterID))), IntegerEntry("Total_Calls", TotalCall), IntegerEntry(("Total_Calls_" + toString(read_OptionCounterID)), TotalCallinSpecificCounter), IntegerEntry((calleraddress + "_Total_Calls"), TotalUserCall), IntegerEntry(((calleraddress + "_Total_Calls_") + toString(read_OptionCounterID)), TotalUserCallinSpecificCounter)] | |
51 | 58 | } | |
52 | 59 | ||
53 | 60 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let Dapp_Address_pub_key = base58'CYbv2nupcWmnVFixN6Q2sxd9ChbDsq1KqXQ66VjsZBJE' | |
5 | 5 | ||
6 | 6 | let oracle_controller_address = addressFromPublicKey(Dapp_Address_pub_key) | |
7 | 7 | ||
8 | 8 | let USDTAssetID = base58'' | |
9 | 9 | ||
10 | 10 | @Callable(i) | |
11 | 11 | func placeoptionCall () = { | |
12 | 12 | let calleraddress = toBase58String(i.caller.bytes) | |
13 | 13 | let ifBlacklisted = getString(this, ("addr_BLACKLISTED_" + calleraddress)) | |
14 | 14 | let read_oracle_status = getStringValue(this, "oracle_status") | |
15 | 15 | let read_OptionCounterID = getIntegerValue(this, "1m_contract_id") | |
16 | 16 | let getbtcdata = getStringValue(this, ("1m_btc_" + toString(read_OptionCounterID))) | |
17 | 17 | let swapLi = split(getbtcdata, "_") | |
18 | 18 | let price = swapLi[0] | |
19 | 19 | let block = parseIntValue(swapLi[2]) | |
20 | 20 | let checkblockgap = (height - block) | |
21 | 21 | let OpionExpireCounter = 1 | |
22 | 22 | let OptionExpireCounterID = (read_OptionCounterID + OpionExpireCounter) | |
23 | 23 | let PreviousCall = match getInteger(this, "Total_Calls") { | |
24 | 24 | case a: Int => | |
25 | 25 | a | |
26 | 26 | case _ => | |
27 | 27 | 0 | |
28 | 28 | } | |
29 | 29 | let TotalCall = (PreviousCall + 1) | |
30 | 30 | let PreviousCallinSpecificCounter = match getInteger(this, ("Total_Calls_" + toString(read_OptionCounterID))) { | |
31 | 31 | case a: Int => | |
32 | 32 | a | |
33 | 33 | case _ => | |
34 | 34 | 0 | |
35 | 35 | } | |
36 | 36 | let TotalCallinSpecificCounter = (PreviousCallinSpecificCounter + 1) | |
37 | 37 | let PreviousUserCall = match getInteger(this, (calleraddress + "_Total_Calls")) { | |
38 | 38 | case a: Int => | |
39 | 39 | a | |
40 | 40 | case _ => | |
41 | 41 | 0 | |
42 | 42 | } | |
43 | 43 | let TotalUserCall = (PreviousUserCall + 1) | |
44 | + | let PreviousUserCallinSpecificCounter = match getInteger(this, ((calleraddress + "_Total_Calls_") + toString(read_OptionCounterID))) { | |
45 | + | case a: Int => | |
46 | + | a | |
47 | + | case _ => | |
48 | + | 0 | |
49 | + | } | |
50 | + | let TotalUserCallinSpecificCounter = (PreviousUserCallinSpecificCounter + 1) | |
44 | 51 | if ((checkblockgap > 2)) | |
45 | 52 | then throw("Something Wrong with Oracle or Height is not matched.") | |
46 | 53 | else if ((read_oracle_status == "Close")) | |
47 | 54 | then throw("Oracle is closed. Wait Until Oracle is Turned On.") | |
48 | 55 | else if ((ifBlacklisted == "Yes")) | |
49 | 56 | then throw((calleraddress + " Address is Blacklisted. Please contact Admin to Whitelist it.")) | |
50 | - | else [StringEntry(((("Call_" + calleraddress) + "_") + toString(TotalUserCall)), price), StringEntry(((("Call_Start_End_" + calleraddress) + "_") + toString(TotalUserCall)), ((toString(read_OptionCounterID) + "_") + toString(OptionExpireCounterID))), IntegerEntry("Total_Calls", TotalCall), IntegerEntry(("Total_Calls_" + toString(read_OptionCounterID)), TotalCallinSpecificCounter), IntegerEntry((calleraddress + "_Total_Calls"), TotalUserCall)] | |
57 | + | else [StringEntry(((("Call_" + calleraddress) + "_") + toString(TotalUserCall)), price), StringEntry(((("Call_Start_End_" + calleraddress) + "_") + toString(TotalUserCall)), ((toString(read_OptionCounterID) + "_") + toString(OptionExpireCounterID))), IntegerEntry("Total_Calls", TotalCall), IntegerEntry(("Total_Calls_" + toString(read_OptionCounterID)), TotalCallinSpecificCounter), IntegerEntry((calleraddress + "_Total_Calls"), TotalUserCall), IntegerEntry(((calleraddress + "_Total_Calls_") + toString(read_OptionCounterID)), TotalUserCallinSpecificCounter)] | |
51 | 58 | } | |
52 | 59 | ||
53 | 60 | ||
54 | 61 | ||
55 | 62 | @Callable(i) | |
56 | 63 | func placeoptionPut () = { | |
57 | 64 | let calleraddress = toBase58String(i.caller.bytes) | |
58 | 65 | let ifBlacklisted = getString(this, ("addr_BLACKLISTED_" + calleraddress)) | |
59 | 66 | let read_oracle_status = getStringValue(this, "oracle_status") | |
60 | 67 | let read_OptionCounterID = getIntegerValue(this, "1m_contract_id") | |
61 | 68 | let getbtcdata = getStringValue(this, ("1m_btc_" + toString(read_OptionCounterID))) | |
62 | 69 | let swapLi = split(getbtcdata, "_") | |
63 | 70 | let price = swapLi[0] | |
64 | 71 | let block = parseIntValue(swapLi[2]) | |
65 | 72 | let checkblockgap = (height - block) | |
66 | 73 | let OpionExpireCounter = 1 | |
67 | 74 | let OptionExpireCounterID = (read_OptionCounterID + OpionExpireCounter) | |
68 | 75 | let PreviousPut = match getInteger(this, "Total_Puts") { | |
69 | 76 | case a: Int => | |
70 | 77 | a | |
71 | 78 | case _ => | |
72 | 79 | 0 | |
73 | 80 | } | |
74 | 81 | let TotalPut = (PreviousPut + 1) | |
75 | 82 | let PreviousUserPut = match getInteger(this, (calleraddress + "_Total_Puts")) { | |
76 | 83 | case a: Int => | |
77 | 84 | a | |
78 | 85 | case _ => | |
79 | 86 | 0 | |
80 | 87 | } | |
81 | 88 | let TotalUserPut = (PreviousUserPut + 1) | |
82 | 89 | if ((checkblockgap > 2)) | |
83 | 90 | then throw("Something Wrong with Oracle or Height is not matched.") | |
84 | 91 | else if ((read_oracle_status == "Close")) | |
85 | 92 | then throw("Oracle is closed. Wait Until Oracle is Turned On.") | |
86 | 93 | else if ((ifBlacklisted == "Yes")) | |
87 | 94 | then throw((calleraddress + " Address is Blacklisted. Please contact Admin to Whitelist it.")) | |
88 | 95 | else [StringEntry(((("Put_" + calleraddress) + "_") + toString(TotalUserPut)), price), StringEntry(((("Put_Start_End_" + calleraddress) + "_") + toString(TotalUserPut)), ((toString(read_OptionCounterID) + "_") + toString(OptionExpireCounterID))), IntegerEntry("Total_Puts", TotalPut), IntegerEntry((calleraddress + "_Total_Puts"), TotalUserPut)] | |
89 | 96 | } | |
90 | 97 | ||
91 | 98 | ||
92 | 99 | ||
93 | 100 | @Callable(i) | |
94 | 101 | func ClaimCall (Call_Sequence) = { | |
95 | 102 | let calleraddress = toBase58String(i.caller.bytes) | |
96 | 103 | let pmt = if ((size(i.payments) == 1)) | |
97 | 104 | then i.payments[0] | |
98 | 105 | else throw("No payment attached, Please Attach Tokens in payment[1].") | |
99 | 106 | let getOptionCallPrice = getStringValue(this, ((("Call_" + calleraddress) + "_") + Call_Sequence)) | |
100 | 107 | let getOptionCall_Sequencedata = getStringValue(this, ((("Call_Start_End_" + calleraddress) + "_") + Call_Sequence)) | |
101 | 108 | let splitStartEndCounter = split(getOptionCall_Sequencedata, "_") | |
102 | 109 | let getStartCounter = splitStartEndCounter[0] | |
103 | 110 | let getEndCounter = splitStartEndCounter[1] | |
104 | 111 | let getbtcdataAtStartCounter = getStringValue(this, ("1m_btc_" + getStartCounter)) | |
105 | 112 | let splitbtcpriceAtStartCounter = split(getbtcdataAtStartCounter, "_") | |
106 | 113 | let getbtcpriceAtStartCounter = splitbtcpriceAtStartCounter[0] | |
107 | 114 | let getbtcdataAtEndCounter = getStringValue(this, ("1m_btc_" + getEndCounter)) | |
108 | 115 | let splitbtcpriceAtEndCounter = split(getbtcdataAtEndCounter, "_") | |
109 | 116 | let getbtcpriceAtEndCounter = splitbtcpriceAtEndCounter[0] | |
110 | 117 | let pricediff = (parseIntValue(getbtcpriceAtEndCounter) - parseIntValue(getbtcpriceAtStartCounter)) | |
111 | 118 | let PreviousCallWin = match getInteger(this, "Total_Option_Call_Wins") { | |
112 | 119 | case a: Int => | |
113 | 120 | a | |
114 | 121 | case _ => | |
115 | 122 | 0 | |
116 | 123 | } | |
117 | 124 | let TotalCallWin = (PreviousCallWin + 1) | |
118 | 125 | let PreviousCallLose = match getInteger(this, "Total_Option_Call_Lose") { | |
119 | 126 | case a: Int => | |
120 | 127 | a | |
121 | 128 | case _ => | |
122 | 129 | 0 | |
123 | 130 | } | |
124 | 131 | let TotalCallLose = (PreviousCallLose + 1) | |
125 | 132 | if ((0 > pricediff)) | |
126 | 133 | then [IntegerEntry("Diff", pricediff), IntegerEntry("Total_Option_Call_Lose", TotalCallLose), StringEntry(((((((((((("c_" + calleraddress) + "_") + Call_Sequence) + "_") + getStartCounter) + "_") + getEndCounter) + "_") + getbtcpriceAtStartCounter) + "_") + getbtcpriceAtEndCounter), "lose"), StringEntry("message", "You lose!"), DeleteEntry(((("Call_" + calleraddress) + "_") + Call_Sequence)), DeleteEntry(((("Call_Start_End_" + calleraddress) + "_") + Call_Sequence))] | |
127 | 134 | else [IntegerEntry("Diff", pricediff), IntegerEntry("Total_Option_Call_Wins", TotalCallWin), StringEntry(((((((((((("c_" + calleraddress) + "_") + Call_Sequence) + "_") + getStartCounter) + "_") + getEndCounter) + "_") + getbtcpriceAtStartCounter) + "_") + getbtcpriceAtEndCounter), "Win"), StringEntry("message", "You Win!"), DeleteEntry(((("Call_" + calleraddress) + "_") + Call_Sequence)), DeleteEntry(((("Call_Start_End_" + calleraddress) + "_") + Call_Sequence))] | |
128 | 135 | } | |
129 | 136 | ||
130 | 137 | ||
131 | 138 | ||
132 | 139 | @Callable(i) | |
133 | 140 | func ClaimPut (Put_Sequence) = { | |
134 | 141 | let calleraddress = toBase58String(i.caller.bytes) | |
135 | 142 | let pmt = if ((size(i.payments) == 1)) | |
136 | 143 | then i.payments[0] | |
137 | 144 | else throw("No payment attached, Please Attach Tokens in payment[1].") | |
138 | 145 | let getOptionPutPrice = getStringValue(this, ((("Put_" + calleraddress) + "_") + Put_Sequence)) | |
139 | 146 | let getOptionPut_Sequencedata = getStringValue(this, ((("Put_Start_End_" + calleraddress) + "_") + Put_Sequence)) | |
140 | 147 | let splitStartEndCounter = split(getOptionPut_Sequencedata, "_") | |
141 | 148 | let getStartCounter = splitStartEndCounter[0] | |
142 | 149 | let getEndCounter = splitStartEndCounter[1] | |
143 | 150 | let getbtcdataAtStartCounter = getStringValue(this, ("1m_btc_" + getStartCounter)) | |
144 | 151 | let splitbtcpriceAtStartCounter = split(getbtcdataAtStartCounter, "_") | |
145 | 152 | let getbtcpriceAtStartCounter = splitbtcpriceAtStartCounter[0] | |
146 | 153 | let getbtcdataAtEndCounter = getStringValue(this, ("1m_btc_" + getEndCounter)) | |
147 | 154 | let splitbtcpriceAtEndCounter = split(getbtcdataAtEndCounter, "_") | |
148 | 155 | let getbtcpriceAtEndCounter = splitbtcpriceAtEndCounter[0] | |
149 | 156 | let pricediff = (parseIntValue(getbtcpriceAtEndCounter) - parseIntValue(getbtcpriceAtStartCounter)) | |
150 | 157 | let PreviousPutWin = match getInteger(this, "Total_Option_Put_Wins") { | |
151 | 158 | case a: Int => | |
152 | 159 | a | |
153 | 160 | case _ => | |
154 | 161 | 0 | |
155 | 162 | } | |
156 | 163 | let TotalPutWin = (PreviousPutWin + 1) | |
157 | 164 | let PreviousPutLose = match getInteger(this, "Total_Option_Put_Lose") { | |
158 | 165 | case a: Int => | |
159 | 166 | a | |
160 | 167 | case _ => | |
161 | 168 | 0 | |
162 | 169 | } | |
163 | 170 | let TotalPutLose = (PreviousPutLose + 1) | |
164 | 171 | if ((pricediff > 0)) | |
165 | 172 | then [IntegerEntry("Diff", pricediff), IntegerEntry("Total_Option_Put_Lose", TotalPutLose), StringEntry(((((((((((("p_" + calleraddress) + "_") + Put_Sequence) + "_") + getStartCounter) + "_") + getEndCounter) + "_") + getbtcpriceAtStartCounter) + "_") + getbtcpriceAtEndCounter), "lose"), StringEntry("message", "You lose!"), DeleteEntry(((("Put_" + calleraddress) + "_") + Put_Sequence)), DeleteEntry(((("Put_Start_End_" + calleraddress) + "_") + Put_Sequence))] | |
166 | 173 | else [IntegerEntry("Diff", pricediff), IntegerEntry("Total_Option_Put_Wins", TotalPutWin), StringEntry(((((((((((("p_" + calleraddress) + "_") + Put_Sequence) + "_") + getStartCounter) + "_") + getEndCounter) + "_") + getbtcpriceAtStartCounter) + "_") + getbtcpriceAtEndCounter), "Win"), StringEntry("message", "You Win!"), DeleteEntry(((("Put_" + calleraddress) + "_") + Put_Sequence)), DeleteEntry(((("Put_Start_End_" + calleraddress) + "_") + Put_Sequence))] | |
167 | 174 | } | |
168 | 175 | ||
169 | 176 | ||
170 | 177 | ||
171 | 178 | @Callable(i) | |
172 | 179 | func calldata (Counter) = { | |
173 | 180 | let getbtcdata = getStringValue(this, ("1m_btc_" + toString(Counter))) | |
174 | 181 | let swapLi = split(getbtcdata, "_") | |
175 | 182 | let price = swapLi[0] | |
176 | 183 | let time = swapLi[1] | |
177 | 184 | let blockheight = swapLi[2] | |
178 | 185 | let div = swapLi[3] | |
179 | 186 | [StringEntry("price", swapLi[0]), StringEntry("time", swapLi[1]), StringEntry("blockheight", swapLi[2]), StringEntry("div", swapLi[3])] | |
180 | 187 | } | |
181 | 188 | ||
182 | 189 | ||
183 | 190 | ||
184 | 191 | @Callable(i) | |
185 | 192 | func OpenOracle () = { | |
186 | 193 | let calleraddress = toBase58String(i.caller.bytes) | |
187 | 194 | if ((i.caller != oracle_controller_address)) | |
188 | 195 | then throw((("This Address is not Authorized. Only " + toString(oracle_controller_address)) + " is Authorized Address to Sign it.")) | |
189 | 196 | else [StringEntry("oracle_status", "Open")] | |
190 | 197 | } | |
191 | 198 | ||
192 | 199 | ||
193 | 200 | ||
194 | 201 | @Callable(i) | |
195 | 202 | func BlackListAddress (UserAddress) = { | |
196 | 203 | let ifBlacklisted = getString(this, ("addr_BLACKLISTED_" + UserAddress)) | |
197 | 204 | let PreviousBlackListAddress = match getInteger(this, "Total_Black_Listed_Address") { | |
198 | 205 | case a: Int => | |
199 | 206 | a | |
200 | 207 | case _ => | |
201 | 208 | 0 | |
202 | 209 | } | |
203 | 210 | let TotalBlackListAddress = (PreviousBlackListAddress + 1) | |
204 | 211 | if ((i.caller != oracle_controller_address)) | |
205 | 212 | then throw((("This Address is not Authorized. Only " + toString(oracle_controller_address)) + " is Authorized Address to Sign it.")) | |
206 | 213 | else if ((ifBlacklisted == "Yes")) | |
207 | 214 | then throw("Address is already available in Blacklist.") | |
208 | 215 | else [StringEntry(("addr_BLACKLISTED_" + UserAddress), "Yes"), IntegerEntry("Total_Black_Listed_Address", TotalBlackListAddress)] | |
209 | 216 | } | |
210 | 217 | ||
211 | 218 | ||
212 | 219 | ||
213 | 220 | @Callable(i) | |
214 | 221 | func DeleteBlackListAddress (UserAddress) = { | |
215 | 222 | let ifBlacklisted = getString(this, ("addr_BLACKLISTED_" + UserAddress)) | |
216 | 223 | let PreviousBlackListAddress = match getInteger(this, "Total_Black_Listed_Address") { | |
217 | 224 | case a: Int => | |
218 | 225 | a | |
219 | 226 | case _ => | |
220 | 227 | 0 | |
221 | 228 | } | |
222 | 229 | let TotalBlackListAddress = (PreviousBlackListAddress - 1) | |
223 | 230 | if ((i.caller != oracle_controller_address)) | |
224 | 231 | then throw((("This Address is not Authorized. Only " + toString(oracle_controller_address)) + " is Authorized Address to Sign it.")) | |
225 | 232 | else if ((ifBlacklisted == "Yes")) | |
226 | 233 | then [DeleteEntry(("addr_BLACKLISTED_" + UserAddress)), IntegerEntry("Total_Black_Listed_Address", TotalBlackListAddress)] | |
227 | 234 | else throw("Address is not available in Blacklist.") | |
228 | 235 | } | |
229 | 236 | ||
230 | 237 | ||
231 | 238 | @Verifier(tx) | |
232 | 239 | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
233 | 240 |
github/deemru/w8io/169f3d6 48.45 ms ◑