From b43300fbcf92008ac1adc87c4b03776a9a4fb4e8 Mon Sep 17 00:00:00 2001 From: Jason Date: Tue, 21 Jun 2022 18:18:32 -0500 Subject: Use Rector to upgrade constructors. Modern PHP versions do not recognize methods with the same name as the class as being constructors. This commit upgrades the code so that constructors are named `__construct`. The upgrade was done automatically using Rector. --- src/SemanticScuttle/db/mysql4.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/SemanticScuttle/db/mysql4.php') diff --git a/src/SemanticScuttle/db/mysql4.php b/src/SemanticScuttle/db/mysql4.php index 0639518..c13bcbd 100644 --- a/src/SemanticScuttle/db/mysql4.php +++ b/src/SemanticScuttle/db/mysql4.php @@ -94,7 +94,7 @@ class sql_db case 'commit': $result = @mysql_query('COMMIT', $this->db_connect_id); $this->transaction = false; - + if (!$result) { @mysql_query('ROLLBACK', $this->db_connect_id); @@ -291,7 +291,7 @@ class sql_db } return $result; } - + return false; } @@ -372,7 +372,7 @@ class sql_db return mysql_escape_string($msg); } } - + function sql_error($sql = '') { if (!$this->return_on_error) @@ -386,7 +386,7 @@ class sql_db { $this->sql_transaction('rollback'); } - + trigger_error($message, E_USER_ERROR); } @@ -463,7 +463,7 @@ class sql_db { $html_table = TRUE; $html_hold .= ''; - + foreach (array_keys($row) as $val) { $html_hold .= ''; @@ -549,4 +549,4 @@ class sql_db } // if ... define -?> \ No newline at end of file +?> -- cgit v1.2.3
' . (($val) ? ucwords(str_replace('_', ' ', $val)) : ' ') . '