@@ -342,7 +342,9 @@ class Socket {
342342 const result = { } ;
343343 result [ stockId ] = this . candlesData [ stockId ] . data ;
344344
345- const cleanResult = _ . mapValues ( result , ( obj ) => {
345+ const cloneResult = this . _deepClone ( result ) ;
346+
347+ const cleanResult = _ . mapValues ( cloneResult , ( obj ) => {
346348 if ( _ . has ( obj , '1' ) ) {
347349 obj . buy = obj [ '1' ] ;
348350 delete obj [ '1' ] ;
@@ -356,7 +358,7 @@ class Socket {
356358 return obj ;
357359 } ) ;
358360
359- this . eventBus . emit ( 'candles' , null , this . _deepClone ( cleanResult ) ) ;
361+ this . eventBus . emit ( 'candles' , null , cleanResult ) ;
360362 } ) ;
361363
362364 this . socketClient . on ( 'candles-delta' , ( delta ) => {
@@ -383,7 +385,9 @@ class Socket {
383385 const result = { } ;
384386 result [ stockId ] = this . candlesData [ stockId ] . data ;
385387
386- const cleanResult = _ . mapValues ( result , ( obj ) => {
388+ const cloneResult = this . _deepClone ( result ) ;
389+
390+ const cleanResult = _ . mapValues ( cloneResult , ( obj ) => {
387391 if ( _ . has ( obj , '1' ) ) {
388392 obj . buy = obj [ '1' ] ;
389393 delete obj [ '1' ] ;
@@ -397,7 +401,7 @@ class Socket {
397401 return obj ;
398402 } ) ;
399403
400- this . eventBus . emit ( 'candles' , null , this . _deepClone ( cleanResult ) ) ;
404+ this . eventBus . emit ( 'candles' , null , cleanResult ) ;
401405 } else {
402406 this . socketClient . emit ( 'candles' , {
403407 stockId : delta . stock_id ,
0 commit comments