tx · HUHqq7f67fSgE3VKu1gkVMxmCoXu1v8v1GjaqPt1WLsv

3MvkyDr4VsmLhsQAg1CfMnsvbsAYJDBXJ1o:  -0.01400000 Waves

2021.12.16 15:47 [1836828] smart account 3MvkyDr4VsmLhsQAg1CfMnsvbsAYJDBXJ1o > SELF 0.00000000 Waves

{ "type": 13, "id": "HUHqq7f67fSgE3VKu1gkVMxmCoXu1v8v1GjaqPt1WLsv", "fee": 1400000, "feeAssetId": null, "timestamp": 1639658832378, "version": 2, "chainId": 84, "sender": "3MvkyDr4VsmLhsQAg1CfMnsvbsAYJDBXJ1o", "senderPublicKey": "EfgW9rhZvzmXU1Fcb1fJTgQzZWmyKDnKM3DkvfUh888x", "proofs": [ "4dDWsh7MdUGAxQxSvvXDKKGA8XkxByKC43uCvhvi3X9epT9LYdXYRFvyAsHBigEtYRnqjuDQ63WVPcet3BjF4kuT" ], "script": "base64:AAIFAAAAAAAAAGwIAhIECgIICBobCgFhEhZjb250cm9sQ29udHJhY3RBZGRyZXNzGgYKAWISAWkaCQoBYxIEYWRkchoOCgFkEgloYXNoZWRVcmkaDAoBZRIHJG1hdGNoMBoHCgFmEgJ0eBoLCgFnEgZ2ZXJpZnkAAAABAAAAAAFhAQAAABoBVKT64jLa+CJeizfFodW99FF4iM0xnvpPsgAAAAEAAAABYgEAAAAGYWRkUmVmAAAAAgAAAAFjAAAAAWQDCQEAAAACIT0AAAACCAgFAAAAAWIAAAAGY2FsbGVyAAAABWJ5dGVzBQAAAAFhCQAAAgAAAAECAAAARUl0J3Mgb3JhY2xlIG1ldGhvZCBhbmQgY2FuIGJlIGNhbGxlZCBvbmx5IGJ5IGNvbnRyb2wgY29udHJhY3QgYWRkcmVzcwQAAAABZQkABB0AAAACBQAAAAR0aGlzBQAAAAFkAwkAAAEAAAACBQAAAAFlAgAAAARVbml0CQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAIFAAAAAWQJAAEsAAAAAgkAASwAAAACBQAAAAFjAgAAAAE6CQACWAAAAAEIBQAAAAFiAAAADXRyYW5zYWN0aW9uSWQFAAAAA25pbAkAAAIAAAABAgAAACpSZWYgZm9yIHNwZWNpZmllZCBoYXNoZWRVcmkgYWxyZWFkeSBleGlzdHMAAAABAAAAAWYBAAAAAWcAAAAACQAB9AAAAAMIBQAAAAFmAAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAABZgAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAFmAAAAD3NlbmRlclB1YmxpY0tleQ6vfCQ=", "height": 1836828, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: D8fxnkLp2vnyKehjgWEYHDq76VFxwMxTamwuBrepRBt1 Next: J8NT99tYiygC5ViLd86pK6ExCH3yG9T5MWgoyNTmF8JJ Diff:
OldNewDifferences
44 let controlContractAddress = base58'3N4xR95UqYH94X8cU4BGPCpPHB6wgMS8jSy'
55
66 @Callable(i)
7-func addRef (encryptedUri,addr) = if ((i.caller.bytes != controlContractAddress))
8- then throw("It's an oracle method and can be called only by the control contract")
9- else match getString(this, encryptedUri) {
7+func addRef (addr,hashedUri) = if ((i.caller.bytes != controlContractAddress))
8+ then throw("It's oracle method and can be called only by control contract address")
9+ else match getString(this, hashedUri) {
1010 case _: Unit =>
11-[StringEntry(encryptedUri, addr)]
11+[StringEntry(hashedUri, ((addr + ":") + toBase58String(i.transactionId)))]
1212 case _ =>
13- throw("Ref for specified encryptedUri already exists")
13+ throw("Ref for specified hashedUri already exists")
1414 }
1515
1616
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let controlContractAddress = base58'3N4xR95UqYH94X8cU4BGPCpPHB6wgMS8jSy'
55
66 @Callable(i)
7-func addRef (encryptedUri,addr) = if ((i.caller.bytes != controlContractAddress))
8- then throw("It's an oracle method and can be called only by the control contract")
9- else match getString(this, encryptedUri) {
7+func addRef (addr,hashedUri) = if ((i.caller.bytes != controlContractAddress))
8+ then throw("It's oracle method and can be called only by control contract address")
9+ else match getString(this, hashedUri) {
1010 case _: Unit =>
11-[StringEntry(encryptedUri, addr)]
11+[StringEntry(hashedUri, ((addr + ":") + toBase58String(i.transactionId)))]
1212 case _ =>
13- throw("Ref for specified encryptedUri already exists")
13+ throw("Ref for specified hashedUri already exists")
1414 }
1515
1616
1717 @Verifier(tx)
1818 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
1919

github/deemru/w8io/026f985 
25.67 ms