File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ def run_test (self):
139139 # Address + Private key + !watchonly
140140 print ("Should import an address with private key" )
141141 address = self .nodes [0 ].validateaddress (self .nodes [0 ].getnewaddress ())
142- timestamp = self .nodes [1 ].getblock (self .nodes [1 ].getbestblockhash ())['time ' ]
142+ timestamp = self .nodes [1 ].getblock (self .nodes [1 ].getbestblockhash ())['mediantime ' ]
143143 result = self .nodes [1 ].importmulti ([{
144144 "scriptPubKey" : {
145145 "address" : address ['address' ]
Original file line number Diff line number Diff line change @@ -1034,7 +1034,7 @@ UniValue importmulti(const JSONRPCRequest& mainRequest)
10341034 EnsureWalletIsUnlocked ();
10351035
10361036 // Verify all timestamps are present before importing any keys.
1037- const int64_t now = chainActive.Tip () ? chainActive.Tip ()->GetBlockTime () : 0 ;
1037+ const int64_t now = chainActive.Tip () ? chainActive.Tip ()->GetMedianTimePast () : 0 ;
10381038 for (const UniValue& data : requests.getValues ()) {
10391039 GetImportTimestamp (data, now);
10401040 }
You can’t perform that action at this time.
0 commit comments