use lnd event emitter from correct scope
This commit is contained in:
		
							parent
							
								
									d0e15eb887
								
							
						
					
					
						commit
						77080f5acd
					
				@ -19,7 +19,7 @@ function subscribeForever (subscribe) {
 | 
			
		||||
    let sub
 | 
			
		||||
    try {
 | 
			
		||||
      return await new Promise((resolve, reject) => {
 | 
			
		||||
        const sub = subscribe(resolve, bail)
 | 
			
		||||
        sub = subscribe(resolve, bail)
 | 
			
		||||
        if (!sub) {
 | 
			
		||||
          return bail(new Error('function passed to subscribeForever must return a subscription object or promise'))
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user