Browse Source

standard formatting fixes

hk-custom-address
Daniel Cousens 10 years ago
parent
commit
e106d02731
  1. 2
      src/ecpair.js
  2. 2
      src/hdnode.js
  3. 2
      test/hdnode.js

2
src/ecpair.js

@ -47,7 +47,7 @@ function ECPair (d, Q, options) {
} }
Object.defineProperty(ECPair.prototype, 'Q', { Object.defineProperty(ECPair.prototype, 'Q', {
get: function() { get: function () {
if (!this.__Q && this.d) { if (!this.__Q && this.d) {
this.__Q = ECPair.curve.G.multiply(this.d) this.__Q = ECPair.curve.G.multiply(this.d)
} }

2
src/hdnode.js

@ -99,7 +99,7 @@ HDNode.fromBase58 = function (string, network) {
var chainCode = buffer.slice(13, 45) var chainCode = buffer.slice(13, 45)
var data, keyPair var data, keyPair
// 33 bytes: private key data (0x00 + k) // 33 bytes: private key data (0x00 + k)
if (version === network.bip32.private) { if (version === network.bip32.private) {
assert.strictEqual(buffer.readUInt8(45), 0x00, 'Invalid private key') assert.strictEqual(buffer.readUInt8(45), 0x00, 'Invalid private key')
data = buffer.slice(46, 78) data = buffer.slice(46, 78)

2
test/hdnode.js

@ -1,4 +1,4 @@
/* global describe, it */ /* global describe, it, beforeEach */
/* eslint-disable no-new */ /* eslint-disable no-new */
var assert = require('assert') var assert = require('assert')

Loading…
Cancel
Save