[bug] remove test code
This commit is contained in:
parent
046eef18e6
commit
1c92a40984
@ -989,15 +989,6 @@ export default class Services {
|
|||||||
throw new Error(`Failed to save updated device: ${e}`);
|
throw new Error(`Failed to save updated device: ${e}`);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// For testing, set last_scan and birthday a few blocks ago
|
|
||||||
device.sp_wallet.last_scan = this.currentBlockHeight - 10;
|
|
||||||
device.sp_wallet.birthday = this.currentBlockHeight - 10;
|
|
||||||
try {
|
|
||||||
this.sdkClient.restore_device(device);
|
|
||||||
} catch (e) {
|
|
||||||
throw new Error(`Failed to restore device: ${e}`);
|
|
||||||
}
|
|
||||||
await this.saveDeviceInDatabase(device);
|
|
||||||
// This is existing device, we need to catch up if last_scan is lagging behind chain_tip
|
// This is existing device, we need to catch up if last_scan is lagging behind chain_tip
|
||||||
if (device.sp_wallet.last_scan < this.currentBlockHeight) {
|
if (device.sp_wallet.last_scan < this.currentBlockHeight) {
|
||||||
// We need to catch up
|
// We need to catch up
|
||||||
|
Loading…
x
Reference in New Issue
Block a user