mirror of
				https://github.com/lingble/chatwoot.git
				synced 2025-10-30 18:47:51 +00:00 
			
		
		
		
	 16fe912fbd
			
		
	
	16fe912fbd
	
	
	
		
			
			Co-authored-by: Nithin David Thomas <webofnithin@gmail.com> Co-authored-by: Sojan Jose <sojan@pepalo.com>
		
			
				
	
	
		
			17 lines
		
	
	
		
			431 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			431 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| import BaseActionCableConnector from '../../shared/helpers/BaseActionCableConnector';
 | |
| 
 | |
| class ActionCableConnector extends BaseActionCableConnector {
 | |
|   constructor(app, pubsubToken) {
 | |
|     super(app, pubsubToken);
 | |
|     this.events = {
 | |
|       'message.created': this.onMessageCreated,
 | |
|     };
 | |
|   }
 | |
| 
 | |
|   onMessageCreated = data => {
 | |
|     this.app.$store.dispatch('conversation/addMessage', data);
 | |
|   };
 | |
| }
 | |
| 
 | |
| export default ActionCableConnector;
 |