mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	Using the ‘a msg per line’ the last line does not get msg.topic passed (#2352)
When using the file-in node and ‘a msg per line’ the last line does not get msg.topic passed. 
In the  
   .on(‘end’, function() { 
code (starting at line 334) the msg is created but no msg.topic is set. Adding 
   topic:msg.topic, 
after line 343 (var m = { payload: spare,) fixes the issue.
			
			
This commit is contained in:
		
				
					committed by
					
						 Dave Conway-Jones
						Dave Conway-Jones
					
				
			
			
				
	
			
			
			
						parent
						
							6026da867b
						
					
				
				
					commit
					22b9df62d1
				
			| @@ -341,6 +341,7 @@ module.exports = function(RED) { | ||||
|                         } | ||||
|                         else if (node.format === "lines") { | ||||
|                             var m = { payload: spare, | ||||
|                                       topic:msg.topic, | ||||
|                                       parts: { | ||||
|                                           index: count, | ||||
|                                           count: count+1, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user