Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
lightning-bits
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bitsoko services
lightning-bits
Commits
a57149cd
Commit
a57149cd
authored
Feb 10, 2022
by
Allan Juma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
255f7bfc
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
8 deletions
+5
-8
lnd-child-process.js
public/lnd-child-process.js
+2
-0
index.js
src/action/index.js
+2
-2
helper.js
src/helper.js
+0
-5
store.js
src/store.js
+1
-1
No files found.
public/lnd-child-process.js
View file @
a57149cd
...
...
@@ -92,6 +92,8 @@ module.exports.startLndProcess = async function({
'--bitcoin.node=neutrino'
,
'--neutrino.connect=btcd-mainnet.lightning.computer'
,
'--neutrino.addpeer=dev.conner.money'
,
'--neutrino.addpeer=lnd-p2p.bitsoko.org'
,
'--neutrino.addpeer=channel.bitsoko.org'
,
'--neutrino.addpeer=mainnet1-btcd.zaphq.io'
,
'--neutrino.addpeer=mainnet2-btcd.zaphq.io'
,
'--neutrino.addpeer=mainnet3-btcd.zaphq.io'
,
...
...
src/action/index.js
View file @
a57149cd
...
...
@@ -159,7 +159,7 @@ when(
async
()
=>
{
await
nap
();
autopilot
.
init
();
if
(
store
.
balanceSatoshis
===
0
)
nav
.
goDeposit
();
if
(
store
.
balanceSatoshis
>
0
&&
store
.
channelBalanceSatoshis
===
0
)
channel
.
connectAndOpen
();
if
(
store
.
balanceSatoshis
<
60000
)
nav
.
goDeposit
();
if
(
store
.
balanceSatoshis
>
25000
&&
store
.
channelBalanceSatoshis
<
(
store
.
balanceSatoshis
*
0.2
)
&&
store
.
pendingChannels
.
length
==
0
&&
store
.
channelBalanceSatoshis
<
20000
)
channel
.
connectAndOpen
();
}
);
src/helper.js
View file @
a57149cd
...
...
@@ -359,12 +359,7 @@ export const sendToEscrow = async (amount, memo) => {
try
{
const
uri
=
'https://gateway.bitsoko.org/escrowInvoice/?action=escrowInvoice&memo='
+
memo
+
'&amount='
+
amount
/
Math
.
pow
(
10
,
8
);
// const uri = 'https://gateway.bitsoko.org/fallback/';
//checkHttpStatus(uri);
//const response = (await fetch(uri)).json();
const
response
=
await
fetch
(
uri
,{
headers
:
{
'Content-Type'
:
'application/json'
},
mode
:
'cors'
});
//const response = await fetch(uri,{method: 'POST', body: {memo: memo, amount: amount/Math.pow(10,8) }, headers: {'Content-Type':'application/json'}, mode: 'cors'});
console
.
log
(
JSON
.
stringify
(
response
.
body
));
var
datStrm
=
await
new
Response
(
response
.
body
,
{
headers
:
{
"Content-Type"
:
"application/json"
}
}).
json
();
return
datStrm
.
data
.
inv
.
payment_request
;
...
...
src/store.js
View file @
a57149cd
...
...
@@ -115,7 +115,7 @@ export class Store {
closedChannels
:
[],
selectedChannel
:
null
,
channel
:
{
pubkeyAtHost
:
'03
3686dc68a8aaacd5caff3bd993cf9a0a4d7a5c5a3bdbcb786002d314de8cbae6@channel.bitsoko.org
'
,
pubkeyAtHost
:
'03
fc96e4e90cbc3f3b57548b0693b77c34ac696a125fe1158aaa9cf3752498fe63@170.75.163.101:9735
'
,
amount
:
'20000'
,
},
paymentRequest
:
null
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment