Commit 0270f0ee by ken

balance

parent 6fa49d73
......@@ -26,9 +26,9 @@ const _handleSocketOpen = function(opened_callback) {
const req = {event: 'addChannel', channel: symbol + '_depth'};
this.send(JSON.stringify(req));
}
let accountReq = `{'accesskey':'${APIKEY}','channel':'${accountInfoChannel}','event':'addChannel'`;
let accountReq = `{'accesskey':'${APIKEY}','channel':'${accountInfoChannel}','event':'addChannel'}`;
const sign = crypto.createHmac('sha1', APISECRET).update(accountReq).digest().toString('base64');
accountReq += `,'sign':'${sign}'}`;
accountReq.replace('}', `,'sign':'${sign}'}`);
console.log(accountReq);
this.send(accountReq);
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment