mirror of
				https://github.com/Ylianst/MeshCentral.git
				synced 2025-03-09 15:40:18 +00:00 
			
		
		
		
	Fixed MeshCtrl.js, #3999
This commit is contained in:
		
							parent
							
								
									e9cff97905
								
							
						
					
					
						commit
						b7231e00e4
					
				
					 1 changed files with 11 additions and 1 deletions
				
			
		
							
								
								
									
										12
									
								
								meshctrl.js
									
										
									
									
									
								
							
							
						
						
									
										12
									
								
								meshctrl.js
									
										
									
									
									
								
							|  | @ -2187,8 +2187,18 @@ function serverConnect() { | |||
|                     console.log(data.result); | ||||
|                     process.exit(); | ||||
|                 } else { | ||||
|                     ws.send(JSON.stringify({ action: 'loginTokens', responseid: 'meshctrl' })); | ||||
|                     if (args.json) { | ||||
|                         console.log(data); | ||||
|                     } else { | ||||
|                         console.log("New login token created."); | ||||
|                         if (data.name) { console.log("Token name: " + data.name); } | ||||
|                         if (data.created) { console.log("Created: " + new Date(data.created).toLocaleString()); } | ||||
|                         if (data.expire) { console.log("Expire: " + new Date(data.expire).toLocaleString()); } | ||||
|                         if (data.tokenUser) { console.log("Username: " + data.tokenUser); } | ||||
|                         if (data.tokenPass) { console.log("Password: " + data.tokenPass); } | ||||
|                     } | ||||
|                 } | ||||
|                 process.exit(); | ||||
|                 break; | ||||
|             } | ||||
|             case 'loginTokens': { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue