Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

biot-core

Package Overview
Dependencies
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

biot-core - npm Package Compare versions

Comparing version 0.2.4 to 0.2.5

56

lib/Channel.js

@@ -124,3 +124,3 @@ const crypto = require('crypto');

await this.updateInDb();
} else if(objMessage.step === 'im_start_channel'){
} else if (objMessage.step === 'im_start_channel') {
this.events.emit('peer_start_channel');

@@ -241,4 +241,3 @@ } else if (objMessage.step === 'addressesAndContract') {

}
}
else if (this.step === 'waiting_transfer' && (signing_path === 'r.2.0' || signing_path === 'r.1.0') && !this.imInitiator) {
} else if (this.step === 'waiting_transfer' && (signing_path === 'r.2.0' || signing_path === 'r.1.0') && !this.imInitiator) {
// this is B

@@ -339,3 +338,3 @@ this.newMyAmount = this.myAmount + this.transferAmount;

bbWallet.sendSignature(from_address, buf_to_sign.toString("base64"), signature, signing_path, top_address);
if(conf.bLight) {
if (conf.bLight) {
setTimeout(() => {

@@ -758,29 +757,24 @@ bbLWallet.refreshLightClientHistory();

return new Promise(((resolve, reject) => {
this.getInputs(this.channelAddress).then(objInputs => {
if (!objInputs) throw new Error('Insufficient funds contract address: ' + this.channelAddress + ' id: ' + this.id);
let opts = {};
opts.paying_addresses = [this.channelAddress];
opts.signing_addresses = [this.myAddress, this.peerAddress];
opts.inputs = objInputs.arrInputs;
opts.input_amount = objInputs.total_input;
opts.outputs = [{
address: objMyContract.shared_address,
amount: 0
}];
opts.signer = libKeys.getLocalSigner(opts, [this.myDeviceAddress, this.peerDeviceAddress], libKeys.signWithLocalPrivateKey);
opts.callbacks = {
ifError: (err) => {
return reject(new Error(err));
},
ifNotEnoughFunds: (err) => {
return reject(new Error(err));
},
ifOk: (objJoint, assocPrivatePayloads, unlock_callback) => {
unlock_callback();
return resolve(objJoint);
}
};
composer.composeJoint(opts);
})
let opts = {};
opts.paying_addresses = [this.channelAddress];
opts.signing_addresses = [this.myAddress, this.peerAddress];
opts.outputs = [{
address: objMyContract.shared_address,
amount: 0
}];
opts.spend_unconfirmed = 'all';
opts.signer = libKeys.getLocalSigner(opts, [this.myDeviceAddress, this.peerDeviceAddress], libKeys.signWithLocalPrivateKey);
opts.callbacks = {
ifError: (err) => {
return reject(new Error(err));
},
ifNotEnoughFunds: (err) => {
return reject(new Error(err));
},
ifOk: (objJoint, assocPrivatePayloads, unlock_callback) => {
unlock_callback();
return resolve(objJoint);
}
};
composer.composeJoint(opts);
}));

@@ -787,0 +781,0 @@ }

{
"name": "biot-core",
"version": "0.2.4",
"version": "0.2.5",
"description": "",

@@ -5,0 +5,0 @@ "main": "core.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc