Skip to content

Commit 0acbfc8

Browse files
authored
Merge pull request #513 from pbs05/master
fix(): Fix beautification issue for TRADE_LITE event type
2 parents caa5497 + 6f725c4 commit 0acbfc8

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "binance",
3-
"version": "2.15.8",
3+
"version": "2.15.9",
44
"description": "Node.js & JavaScript SDK for Binance REST APIs & WebSockets, with TypeScript & end-to-end tests.",
55
"main": "lib/index.js",
66
"types": "lib/index.d.ts",

src/util/beautifier-maps.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,22 @@ export const BEAUTIFIER_EVENT_MAP = {
220220
T: 'transactionTime',
221221
o: 'order',
222222
},
223+
TRADE_LITEEvent: {
224+
e: 'eventType',
225+
E: 'eventTime',
226+
T: 'transactionTime',
227+
o: 'order',
228+
s: 'symbol',
229+
q: 'originalQuantity',
230+
p: 'originalPrice',
231+
m: 'isMakerSide',
232+
c: 'clientOrderId',
233+
S: 'side',
234+
L: 'lastFilledPrice',
235+
l: 'lastFilledQuantity',
236+
t: 'tradeId',
237+
i: 'orderId',
238+
},
223239
CONDITIONAL_ORDER_TRIGGER_REJECTEvent: {
224240
e: 'eventType',
225241
E: 'eventTime',

src/websocket-client.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,7 @@ export class WebsocketClient extends EventEmitter {
436436
'ACCOUNT_UPDATE',
437437
'MARGIN_CALL',
438438
'ORDER_TRADE_UPDATE',
439+
'TRADE_LITE',
439440
'CONDITIONAL_ORDER_TRIGGER_REJECT',
440441
].includes(eventType)
441442
) {

0 commit comments

Comments
 (0)