Skip to content
Snippets Groups Projects
Commit a7cb2b02 authored by nveid's avatar nveid
Browse files

Reversed the logic one place in the mysql client plugin

parent 1d8f7f15
No related branches found
No related tags found
2 merge requests!46Master,!21Master
...@@ -131,7 +131,7 @@ class mysql_clientdb_plugin { ...@@ -131,7 +131,7 @@ class mysql_clientdb_plugin {
//* Connect to the database //* Connect to the database
$link = new mysqli($clientdb_host, $clientdb_user, $clientdb_password); $link = new mysqli($clientdb_host, $clientdb_user, $clientdb_password);
if (!$link->connect_error) { if ($link->connect_error) {
$app->log('Unable to connect to mysql'.$link->connect_error,LOGLEVEL_ERROR); $app->log('Unable to connect to mysql'.$link->connect_error,LOGLEVEL_ERROR);
return; return;
} }
...@@ -184,7 +184,7 @@ class mysql_clientdb_plugin { ...@@ -184,7 +184,7 @@ class mysql_clientdb_plugin {
//* Connect to the database //* Connect to the database
$link = new mysqli($clientdb_host, $clientdb_user, $clientdb_password); $link = new mysqli($clientdb_host, $clientdb_user, $clientdb_password);
if (!$link) { if ($link->connect_error) {
$app->log('Unable to connect to the database: '.$link->connect_error,LOGLEVEL_ERROR); $app->log('Unable to connect to the database: '.$link->connect_error,LOGLEVEL_ERROR);
return; return;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment