From 20991add684a0a717deda5d66394b3382d5ff3c3 Mon Sep 17 00:00:00 2001 From: Patrick Teichmann Date: Mon, 13 Sep 2021 12:20:10 +0200 Subject: [PATCH] Fixed issue #17592: database update 450 fails --- application/helpers/update/updatedb_helper.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/application/helpers/update/updatedb_helper.php b/application/helpers/update/updatedb_helper.php index 3daac29d99c..01d311dd431 100644 --- a/application/helpers/update/updatedb_helper.php +++ b/application/helpers/update/updatedb_helper.php @@ -5229,7 +5229,7 @@ function decryptArchivedTables450($oDB) // recrypt tokens if ($archivedTableSettings['tbl_type'] === 'token') { // skip if the encryption status is unknown - if (isset($archivedTableSettingsProperties) && $archivedTableSettingsProperties[0] !== 'unknown') { + if (!empty($archivedTableSettingsProperties) && $archivedTableSettingsProperties[0] !== 'unknown') { $tokenencryptionoptions = $archivedTableSettingsProperties; // default attributes @@ -5238,7 +5238,7 @@ function decryptArchivedTables450($oDB) } } // skip if the encryption status is unknown - if (isset($archivedTableSettingsAttributes) && $archivedTableSettingsAttributes[0] !== 'unknown') { + if (!empty($archivedTableSettingsAttributes) && $archivedTableSettingsAttributes[0] !== 'unknown') { // find custom attribute column names $table = tableExists("{{{$archivedTableSettings['tbl_name']}}}"); if (!$table) { @@ -5278,7 +5278,7 @@ function decryptArchivedTables450($oDB) } // recrypt responses // skip if the encryption status is unknown - if ($archivedTableSettings['tbl_type'] === 'response' && isset($archivedTableSettingsProperties) && $archivedTableSettingsProperties[0] !== 'unknown') { + if ($archivedTableSettings['tbl_type'] === 'response' && !empty($archivedTableSettingsProperties) && $archivedTableSettingsProperties[0] !== 'unknown') { $responsesCount = $oDB->createCommand() ->select('count(*)') ->from("{{{$archivedTableSettings['tbl_name']}}}")