Browse Source
feat(lnd): update lnd to latest master build
renovate/lint-staged-8.x
Tom Kirkpatrick
6 years ago
No known key found for this signature in database
GPG Key ID: 72203A8EC5967EA8
5 changed files with
10 additions and
26 deletions
-
app/lib/utils/btc.js
-
app/lib/zap/controller.js
-
app/reducers/invoice.js
-
package.json
-
resources/rpc.proto
|
|
@ -25,7 +25,7 @@ export function btcToBits(btc) { |
|
|
|
|
|
|
|
export function btcToFiat(btc, price) { |
|
|
|
const amount = parseFloat(btc * price).toFixed(2) |
|
|
|
return (btc > 0 && amount <= 0) ? '< 0.01' : numberWithCommas(amount) |
|
|
|
return btc > 0 && amount <= 0 ? '< 0.01' : numberWithCommas(amount) |
|
|
|
} |
|
|
|
|
|
|
|
////////////////////////////
|
|
|
@ -76,17 +76,6 @@ export function satoshisToFiat(satoshis, price) { |
|
|
|
return btcToFiat(satoshisToBtc(satoshis), price) |
|
|
|
} |
|
|
|
|
|
|
|
////////////////////////////////
|
|
|
|
// millisatoshis to satoshis //
|
|
|
|
//////////////////////////////
|
|
|
|
|
|
|
|
export function millisatoshisToSatoshis(millisatoshis) { |
|
|
|
if (millisatoshis === undefined || millisatoshis === null || millisatoshis === '') return null |
|
|
|
|
|
|
|
return Math.round(millisatoshis / 1000) |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
export function renderCurrency(currency) { |
|
|
|
switch (currency) { |
|
|
|
case 'btc': |
|
|
@ -156,8 +145,6 @@ export default { |
|
|
|
satoshisToBits, |
|
|
|
satoshisToFiat, |
|
|
|
|
|
|
|
millisatoshisToSatoshis, |
|
|
|
|
|
|
|
renderCurrency, |
|
|
|
|
|
|
|
convert |
|
|
|
|
|
@ -386,7 +386,7 @@ class ZapController { |
|
|
|
const shutdownTimeout = setTimeout(() => { |
|
|
|
this.neutrino.removeListener('close', closeHandler) |
|
|
|
if (this.neutrino) { |
|
|
|
mainLog.warn('Graceful shutdown failed to complete within 30 seconds.') |
|
|
|
mainLog.warn('Graceful shutdown failed to complete within 10 seconds.') |
|
|
|
this.neutrino.kill() |
|
|
|
resolve() |
|
|
|
} |
|
|
|
|
|
@ -40,10 +40,7 @@ export const UPDATE_INVOICE = 'UPDATE_INVOICE' |
|
|
|
|
|
|
|
// Decorate invoice object with custom/computed properties.
|
|
|
|
const decorateInvoice = invoice => { |
|
|
|
invoice.finalAmount = invoice.value |
|
|
|
if (invoice.amt_paid) { |
|
|
|
invoice.finalAmount = btc.millisatoshisToSatoshis(invoice.amt_paid) |
|
|
|
} |
|
|
|
invoice.finalAmount = invoice.amt_paid ? invoice.amt_paid : invoice.value |
|
|
|
return invoice |
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -42,7 +42,7 @@ |
|
|
|
"config": { |
|
|
|
"style_paths": "app/styles/*.scss app/components/**/*.scss", |
|
|
|
"lnd-binary": { |
|
|
|
"binaryVersion": "0.4.2-beta-913-g26f68da5", |
|
|
|
"binaryVersion": "0.5-beta-rc1-52-gbaee07ef", |
|
|
|
"binarySite": "https://github.com/LN-Zap/lnd/releases/download" |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
@ -1,4 +1,4 @@ |
|
|
|
// Imported from https://github.com/lightningnetwork/lnd/blob/26f68da5b2883885fcf6a8e79b3fc9bb12cc9eef/lnrpc/rpc.proto |
|
|
|
// Imported from https://github.com/lightningnetwork/lnd/blob/baee07ef480c15a731e0c87dc98d27269c5a80fa/lnrpc/rpc.proto |
|
|
|
syntax = "proto3"; |
|
|
|
|
|
|
|
// import "google/api/annotations.proto"; |
|
|
@ -23,7 +23,7 @@ package lnrpc; |
|
|
|
* |
|
|
|
* More information on how exactly the gRPC documentation is generated from |
|
|
|
* this proto file can be found here: |
|
|
|
* https://github.com/MaxFangX/lightning-api |
|
|
|
* https://github.com/lightninglabs/lightning-api |
|
|
|
*/ |
|
|
|
|
|
|
|
// The WalletUnlocker service is used to set up a wallet password for |
|
|
|