Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
kucoin
Overview
Overview
Details
Activity
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
rongjun
kucoin
Commits
09a68af9
Commit
09a68af9
authored
Oct 06, 2018
by
zihan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
处理浮点数运算
parent
b2fee23b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
api_kucoin.js
api_kucoin.js
+1
-2
No files found.
api_kucoin.js
View file @
09a68af9
...
@@ -10,7 +10,6 @@ const constants = require('./constants');
...
@@ -10,7 +10,6 @@ const constants = require('./constants');
const
{
IPs
,
mergeDepth
}
=
require
(
'./util'
);
const
{
IPs
,
mergeDepth
}
=
require
(
'./util'
);
let
totalOrderbook
=
{};
let
totalOrderbook
=
{};
//todo 这里还要处理浮点数运算的问题
let
getUpdatedData
=
function
(
currentData
,
response
)
{
let
getUpdatedData
=
function
(
currentData
,
response
)
{
const
updateData
=
[];
const
updateData
=
[];
...
@@ -37,7 +36,7 @@ let getUpdatedData = function (currentData, response) {
...
@@ -37,7 +36,7 @@ let getUpdatedData = function (currentData, response) {
updateData
.
push
([
response
.
data
.
price
,
response
.
data
.
count
]);
updateData
.
push
([
response
.
data
.
price
,
response
.
data
.
count
]);
}
else
{
}
else
{
// updateData = [[response.data.price, newCount]];
// updateData = [[response.data.price, newCount]];
updateData
.
push
([
response
.
data
.
price
,
newCount
]);
updateData
.
push
([
response
.
data
.
price
,
newCount
.
toPrecision
(
12
)
]);
}
}
return
updateData
;
return
updateData
;
};
};
...
...
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