diff --git a/ChangeLog b/ChangeLog index 0634cc0170..f0d4536ba1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -32,6 +32,7 @@ phpMyAdmin - ChangeLog 4.4.6.0 (not yet released) - bug #4890 webkitStorageInfo and webkitIndexedDB is deprecated +- bug #4892 Undefined variable: unique_conditions 4.4.5.0 (2015-05-05) - bug Table overhead stats: missing space before the unit diff --git a/libraries/DisplayResults.class.php b/libraries/DisplayResults.class.php index 6e00d3ad38..9f5e327d33 100644 --- a/libraries/DisplayResults.class.php +++ b/libraries/DisplayResults.class.php @@ -2871,7 +2871,7 @@ class PMA_DisplayResults $row_info = $this->_getRowInfoForSpecialLinks($row, $col_order); - $previousMetaOrgTable = ''; + $uniqueConditionMap = array(); $columnCount = $this->__get('fields_cnt'); for ($currentColumn = 0; @@ -3024,8 +3024,7 @@ class PMA_DisplayResults * costly and does not need to be called if we already know * the conditions for the current table. */ - - if ($meta->orgtable != $previousMetaOrgTable) { + if (! isset($uniqueConditionMap[$meta->orgtable])) { $unique_conditions = PMA_Util::getUniqueCondition( $dt_result, $this->__get('fields_cnt'), @@ -3034,13 +3033,13 @@ class PMA_DisplayResults false, $meta->orgtable ); - $previousMetaOrgTable = $meta->orgtable; + $uniqueConditionMap[$meta->orgtable] = $unique_conditions; } $transform_url_params = array( 'db' => $this->__get('db'), 'table' => $meta->orgtable, - 'where_clause' => $unique_conditions[0], + 'where_clause' => $uniqueConditionMap[$meta->orgtable][0], 'transform_key' => $meta->orgname );