From c292d017239dc6f61f3d1fe60297e24a06d57f4d Mon Sep 17 00:00:00 2001 From: Hauke Altmann Date: Fri, 17 Apr 2015 09:59:28 +0200 Subject: [PATCH] bug fix: substring is not a PHP function %-) --- include/dbstructure.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/dbstructure.php b/include/dbstructure.php index 012bb6f0b..9faede0ca 100644 --- a/include/dbstructure.php +++ b/include/dbstructure.php @@ -153,7 +153,7 @@ function update_structure($verbose, $action, $tables=null, $definition=null) { } else { // Drop the index if it isn't present in the definition and index name doesn't start with "local_" foreach ($database[$name]["indexes"] AS $indexname => $fieldnames) - if (!isset($structure["indexes"][$indexname]) && substring($indexname, 0, 5) != 'local_') { + if (!isset($structure["indexes"][$indexname]) && substr($indexname, 0, 5) != 'local_') { $sql2=db_drop_index($indexname); if ($sql3 == "") $sql3 = "ALTER TABLE `".$name."` ".$sql2;