* Sat May 24 2025 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-11.sme
- fix issue with standalone and netserver mode [SME: 13012]
This commit is contained in:
		@@ -253,7 +253,10 @@ sub get_ups_status {
 | 
			
		||||
	} elsif ($nutmode eq 'netclient'){
 | 
			
		||||
    return $c->get_status_from_device($cdb->get_prop('nut','ClientUPS'));
 | 
			
		||||
	} else {
 | 
			
		||||
		return $c->get_status_from_device($cdb->get_prop('nut','MasterUPS'));
 | 
			
		||||
		# TODO: could enumerate all the upses using
 | 
			
		||||
                # my @upses = grep(/^nut-driver\@[a-zA-Z0-9_-]+$/, $DB->keys);
 | 
			
		||||
                # we will only use the default first one for the moment nut-driver@ups for ups named "ups"
 | 
			
		||||
		return $c->get_status_from_device("ups");
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user