Skip to content

Commit

Permalink
Merge branch 'QA_5_0'
Browse files Browse the repository at this point in the history
Signed-off-by: William Desportes <williamdes@wdes.fr>
  • Loading branch information
williamdes committed Oct 21, 2019
2 parents 3814d88 + 67a3788 commit 1fb7e78
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 13 deletions.
2 changes: 2 additions & 0 deletions ChangeLog
Expand Up @@ -57,6 +57,8 @@ phpMyAdmin - ChangeLog
- issue #15511 Fixed exporting users after a delete will delete all selected users on "Users" page
- issue #14598 Fixed checking referencial integrity on "Operations" page
- issue #14433 Fix "You do not have privileges to manipulate with the users!" on root superadmin
- issue #15391 Fix GIS polygon of a geometry field is not drawn on "GIS visualization"
- issue #15311 Fix adjust privileges on copy database fails with MariaDB

4.9.1 (2019-09-20)
- issue #15313 Added support for Twig 2
Expand Down
8 changes: 4 additions & 4 deletions libraries/classes/Gis/GisVisualization.php
Expand Up @@ -583,22 +583,22 @@ private function _scaleDataSet(array $data)

// Update minimum/maximum values for x and y coordinates.
$c_maxX = (float) $scale_data['maxX'];
if (! isset($min_max['maxX']) || $c_maxX > $min_max['maxX']) {
if ($min_max['maxX'] === 0.0 || $c_maxX > $min_max['maxX']) {
$min_max['maxX'] = $c_maxX;
}

$c_minX = (float) $scale_data['minX'];
if (! isset($min_max['minX']) || $c_minX < $min_max['minX']) {
if ($min_max['minX'] === 0.0 || $c_minX < $min_max['minX']) {
$min_max['minX'] = $c_minX;
}

$c_maxY = (float) $scale_data['maxY'];
if (! isset($min_max['maxY']) || $c_maxY > $min_max['maxY']) {
if ($min_max['maxY'] === 0.0 || $c_maxY > $min_max['maxY']) {
$min_max['maxY'] = $c_maxY;
}

$c_minY = (float) $scale_data['minY'];
if (! isset($min_max['minY']) || $c_minY < $min_max['minY']) {
if ($min_max['minY'] === 0.0 || $c_minY < $min_max['minY']) {
$min_max['minY'] = $c_minY;
}
}
Expand Down
14 changes: 5 additions & 9 deletions libraries/classes/Operations.php
Expand Up @@ -700,15 +700,11 @@ public function adjustPrivilegesCopyDb($oldDb, $newname)

foreach ($old_privs_db as $old_priv) {
$newDb_db_privs_query = 'INSERT INTO ' . Util::backquote('db')
. ' VALUES("' . $old_priv[0] . '", "' . $newname . '", "'
. $old_priv[2] . '", "' . $old_priv[3] . '", "' . $old_priv[4]
. '", "' . $old_priv[5] . '", "' . $old_priv[6] . '", "'
. $old_priv[7] . '", "' . $old_priv[8] . '", "' . $old_priv[9]
. '", "' . $old_priv[10] . '", "' . $old_priv[11] . '", "'
. $old_priv[12] . '", "' . $old_priv[13] . '", "' . $old_priv[14]
. '", "' . $old_priv[15] . '", "' . $old_priv[16] . '", "'
. $old_priv[17] . '", "' . $old_priv[18] . '", "' . $old_priv[19]
. '", "' . $old_priv[20] . '", "' . $old_priv[21] . '");';
. ' VALUES("' . $old_priv[0] . '", "' . $newname . '"';
for ($i = 2; $i < count($old_priv); $i++) {
$newDb_db_privs_query .= ', "' . $old_priv[$i] . '"';
}
$newDb_db_privs_query .= ')';

$this->dbi->query($newDb_db_privs_query);
}
Expand Down

0 comments on commit 1fb7e78

Please sign in to comment.