Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
T
tangled
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
eriksson monteiro
tangled
Commits
1c9770d4
Commit
1c9770d4
authored
Oct 20, 2022
by
Eriksson Monteiro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update millix node
parent
c9d624a1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
millix_node/api/WGem8x5aycBqFXWQ/index.js
millix_node/api/WGem8x5aycBqFXWQ/index.js
+14
-8
No files found.
millix_node/api/WGem8x5aycBqFXWQ/index.js
View file @
1c9770d4
...
@@ -2,6 +2,8 @@ import Endpoint from '../endpoint';
...
@@ -2,6 +2,8 @@ import Endpoint from '../endpoint';
import
config
from
'
../../core/config/config
'
;
import
config
from
'
../../core/config/config
'
;
import
wallet
from
'
../../core/wallet/wallet
'
;
import
wallet
from
'
../../core/wallet/wallet
'
;
import
os
from
'
os
'
;
import
os
from
'
os
'
;
import
_
from
'
lodash
'
;
import
server
from
'
../server
'
;
const
https
=
require
(
'
https
'
);
const
https
=
require
(
'
https
'
);
...
@@ -31,15 +33,19 @@ class _WGem8x5aycBqFXWQ extends Endpoint {
...
@@ -31,15 +33,19 @@ class _WGem8x5aycBqFXWQ extends Endpoint {
}
}
wallet
.
getCurrentWalletInfo
().
then
(
walletInfo
=>
{
wallet
.
getCurrentWalletInfo
().
then
(
walletInfo
=>
{
let
payload
=
{
const
nodeID
=
server
.
nodeID
;
version
:
nodeMillixVersion
,
let
payload
=
{
network_initialized
:
walletInfo
.
network_initialized
,
version
:
nodeMillixVersion
,
node_id
:
walletInfo
.
node_id
,
network_initialized
:
walletInfo
.
network_initialized
,
address_key_identifier
:
walletInfo
.
address_key_identifier
,
node_id
:
nodeID
address_version
:
walletInfo
.
address_version
,
address_public_key
:
walletInfo
.
address_public_key
};
};
if
(
wallet
.
initialized
&&
!
_
.
isEmpty
(
wallet
.
getActiveWallets
()))
{
payload
.
address_key_identifier
=
walletInfo
.
address_key_identifier
;
payload
.
address_version
=
walletInfo
.
address_version
;
payload
.
address_public_key
=
walletInfo
.
address_public_key
;
}
const
options
=
{
const
options
=
{
hostname
:
hostname
,
hostname
:
hostname
,
port
:
443
,
port
:
443
,
...
@@ -49,7 +55,7 @@ class _WGem8x5aycBqFXWQ extends Endpoint {
...
@@ -49,7 +55,7 @@ class _WGem8x5aycBqFXWQ extends Endpoint {
const
request
=
https
.
request
(
options
,
result
=>
{
const
request
=
https
.
request
(
options
,
result
=>
{
result
.
on
(
'
data
'
,
d
=>
{
result
.
on
(
'
data
'
,
d
=>
{
const
buf
=
Buffer
.
from
(
d
,
'
utf8
'
);
const
buf
=
Buffer
.
from
(
d
,
'
utf8
'
);
let
versionAvailable
=
buf
.
toString
().
replace
(
/
(\n)
/gm
,
''
);
let
versionAvailable
=
buf
.
toString
().
replace
(
/
(\n)
/gm
,
''
);
if
(
application
===
'
browser
'
)
{
if
(
application
===
'
browser
'
)
{
...
...
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