tx · BnrwJ2pAKoaXF3LgupZ4mMewYjtexM5oCaVjMN6wrdf1

3NB7gYiKko9aybm4jjEFdrTjTsvQWpcCdaS:  -0.05000000 Waves

2022.01.25 23:28 [1894916] smart account 3NB7gYiKko9aybm4jjEFdrTjTsvQWpcCdaS > SELF 0.00000000 Waves

{ "type": 13, "id": "BnrwJ2pAKoaXF3LgupZ4mMewYjtexM5oCaVjMN6wrdf1", "fee": 5000000, "feeAssetId": null, "timestamp": 1643142538991, "version": 2, "chainId": 84, "sender": "3NB7gYiKko9aybm4jjEFdrTjTsvQWpcCdaS", "senderPublicKey": "CMZuFNW2DCrX1xFXYGgE6QrERYLGpncVxcAKhxyEsoAa", "proofs": [ "4jXqEvxxriMTMytzXSEj8CPYTcgY3xeWBQFysZA4VEYkrU3GyU1mYD97zY6WnVWU9UTWac6qKCguFVvGaFVTkhmW" ], "script": "base64:AAIFAAAAAAAAABgIAhIDCgEIEgQKAggIEgQKAggBEgMKAQgAAAAEAAAAAAxhZG1pbkFkZHJlc3MJAQAAAAt2YWx1ZU9yRWxzZQAAAAIJAAQdAAAAAgUAAAAEdGhpcwIAAAAFYWRtaW4CAAAAAAEAAAAHaXNBZG1pbgAAAAEAAAANY2FsbGVyQWRkcmVzcwMJAAAAAAAAAgUAAAANY2FsbGVyQWRkcmVzcwkAAlkAAAABBQAAAAxhZG1pbkFkZHJlc3MGBwEAAAAMd3JpdGVJbnRlZ2VyAAAAAgAAAANrZXkAAAAMaW50ZWdlclZhbHVlCQEAAAAMSW50ZWdlckVudHJ5AAAAAgUAAAADa2V5BQAAAAxpbnRlZ2VyVmFsdWUBAAAAC3dyaXRlU3RyaW5nAAAAAgAAAANrZXkAAAALc3RyaW5nVmFsdWUJAQAAAAtTdHJpbmdFbnRyeQAAAAIFAAAAA2tleQUAAAALc3RyaW5nVmFsdWUAAAAEAAAAAWkBAAAABXNldHVwAAAAAQAAAAttYWluQWRkcmVzcwMJAQAAAAEhAAAAAQkBAAAACWlzRGVmaW5lZ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kbWluIGFkZHJlc3MhAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkCRPcW", "height": 1894916, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: UnoRdY5N9CXDWmxqpTT8NpV2XSLfreuC7hmDXJehFco Next: CGobikNVzPpL5pwBeXERorsdL4a2scP7oqEweJgPLJ7 Diff:
OldNewDifferences
1515
1616
1717 @Callable(i)
18-func setup (adminAddress,mainAddress) = if (!(isDefined(getString(this, "admin"))))
19- then [writeString("admin", adminAddress), writeString("main", mainAddress)]
18+func setup (mainAddress) = if (!(isDefined(getString(this, "admin"))))
19+ then [writeString("admin", toBase58String(i.caller.bytes)), writeString("main", mainAddress)]
2020 else throw("Pool already setup!")
2121
2222
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let adminAddress = valueOrElse(getString(this, "admin"), "")
55
66 func isAdmin (callerAddress) = if ((callerAddress == fromBase58String(adminAddress)))
77 then true
88 else false
99
1010
1111 func writeInteger (key,integerValue) = IntegerEntry(key, integerValue)
1212
1313
1414 func writeString (key,stringValue) = StringEntry(key, stringValue)
1515
1616
1717 @Callable(i)
18-func setup (adminAddress,mainAddress) = if (!(isDefined(getString(this, "admin"))))
19- then [writeString("admin", adminAddress), writeString("main", mainAddress)]
18+func setup (mainAddress) = if (!(isDefined(getString(this, "admin"))))
19+ then [writeString("admin", toBase58String(i.caller.bytes)), writeString("main", mainAddress)]
2020 else throw("Pool already setup!")
2121
2222
2323
2424 @Callable(i)
2525 func updateStringEntry (key,stringValue) = if (isAdmin(i.caller.bytes))
2626 then [writeString(key, stringValue)]
2727 else throw("Address does not match with admin address!")
2828
2929
3030
3131 @Callable(i)
3232 func updateIntegerEntry (key,integerValue) = if (isAdmin(i.caller.bytes))
3333 then [writeInteger(key, integerValue)]
3434 else throw("Address does not match with admin address!")
3535
3636
3737
3838 @Callable(i)
3939 func deleteStorageEntry (key) = if (isAdmin(i.caller.bytes))
4040 then [DeleteEntry(key)]
4141 else throw("Address does not match with admin address!")
4242
4343
4444 @Verifier(tx)
4545 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
4646

github/deemru/w8io/169f3d6 
58.31 ms