mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Fix MySQL Host Logic
This commit is contained in:
@@ -268,8 +268,7 @@ function ss_get_mysql_stats( $options ) {
|
|||||||
$heartbeat = isset($options['heartbeat']) ? $options['heartbeat'] : $heartbeat;
|
$heartbeat = isset($options['heartbeat']) ? $options['heartbeat'] : $heartbeat;
|
||||||
# If there is a port, or if it's a non-standard port, we add ":$port" to the
|
# If there is a port, or if it's a non-standard port, we add ":$port" to the
|
||||||
# hostname.
|
# hostname.
|
||||||
$host_str = $host
|
$host_str = $host.($port != 3306 ? ":$port" : '');
|
||||||
. $port != 3306 ? ":$port" : '';
|
|
||||||
debug(array('connecting to', $host_str, $user, $pass));
|
debug(array('connecting to', $host_str, $user, $pass));
|
||||||
if (!extension_loaded('mysql') ) {
|
if (!extension_loaded('mysql') ) {
|
||||||
debug("The MySQL extension is not loaded");
|
debug("The MySQL extension is not loaded");
|
||||||
|
|||||||
Reference in New Issue
Block a user