mirror of
				https://github.com/karl0ss/homepage.git
				synced 2025-11-04 00:10:57 +00:00 
			
		
		
		
	Fix: handle proxmoxbackupserver without datastore (#3979)
This commit is contained in:
		
							parent
							
								
									6b1080ad43
								
							
						
					
					
						commit
						9243187490
					
				@ -29,7 +29,7 @@ export default function Component({ service }) {
 | 
			
		||||
    );
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  const datastoreUsage = (datastoreData.data[0].used / datastoreData.data[0].total) * 100;
 | 
			
		||||
  const datastoreUsage = datastoreData.data ? (datastoreData.data[0].used / datastoreData.data[0].total) * 100 : 0;
 | 
			
		||||
  const cpuUsage = hostData.data.cpu * 100;
 | 
			
		||||
  const memoryUsage = (hostData.data.memory.used / hostData.data.memory.total) * 100;
 | 
			
		||||
  const failedTasks = tasksData.total >= 100 ? "99+" : tasksData.total;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user