File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -36,15 +36,15 @@ class MyStream extends Readable {
3636      case  0 :
3737        return  this . push ( null ) ; 
3838      case  1 :
39-         return  setTimeout ( function ( )  { 
39+         return  setTimeout ( ( )   =>  { 
4040          this . push ( 'last chunk' ) ; 
41-         } . bind ( this ) ,  100 ) ; 
41+         } ,  100 ) ; 
4242      case  2 :
4343        return  this . push ( 'second to last chunk' ) ; 
4444      case  3 :
45-         return  process . nextTick ( function ( )  { 
45+         return  process . nextTick ( ( )   =>  { 
4646          this . push ( 'first chunk' ) ; 
47-         } . bind ( this ) ) ; 
47+         } ) ; 
4848      default :
4949        throw  new  Error ( '?' ) ; 
5050    } 
Original file line number Diff line number Diff line change @@ -211,14 +211,14 @@ const Transform = require('_stream_transform');
211211    if  ( ! chunk ) 
212212      chunk  =  '' ; 
213213    const  s  =  chunk . toString ( ) ; 
214-     setTimeout ( function ( )  { 
214+     setTimeout ( ( )   =>  { 
215215      this . state  +=  s . charAt ( 0 ) ; 
216216      if  ( this . state . length  ===  3 )  { 
217217        pt . push ( Buffer . from ( this . state ) ) ; 
218218        this . state  =  '' ; 
219219      } 
220220      cb ( ) ; 
221-     } . bind ( this ) ,  10 ) ; 
221+     } ,  10 ) ; 
222222  } ; 
223223
224224  pt . _flush  =  function ( cb )  { 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments