Initial LND socket has no args, handle
This commit is contained in:
parent
c795009e94
commit
6354962b2f
1 changed files with 11 additions and 1 deletions
|
|
@ -57,7 +57,16 @@ module.exports = (
|
||||||
|
|
||||||
const { services } = LightningServices
|
const { services } = LightningServices
|
||||||
|
|
||||||
const { service, method, args: unParsed } = socket.handshake.auth
|
const {
|
||||||
|
service,
|
||||||
|
method,
|
||||||
|
args: unParsed,
|
||||||
|
isInitial
|
||||||
|
} = socket.handshake.auth
|
||||||
|
|
||||||
|
if (isInitial) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
const args = JSON.parse(unParsed)
|
const args = JSON.parse(unParsed)
|
||||||
|
|
||||||
|
|
@ -100,6 +109,7 @@ module.exports = (
|
||||||
call.write(args)
|
call.write(args)
|
||||||
})
|
})
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
logger.error(err)
|
||||||
logger.error('LNDRPC: ' + err.message)
|
logger.error('LNDRPC: ' + err.message)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue