Skip to content

Commit

Permalink
Fix bug #2718862, error when commenting on database
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert Treat committed Jul 12, 2009
1 parent cc25aca commit 2d92e82
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions classes/database/Postgres.php
Expand Up @@ -646,11 +646,13 @@ function alterDatabase($dbName, $newName, $newOwner = '', $comment = '') {
}
}

$status = $this->alterDatabaseOwner($newName, $newOwner);
if ($status != 0) {
$this->rollbackTransaction();
return -2;
}
if ($newOwner != '') {
$status = $this->alterDatabaseOwner($newName, $newOwner);
if ($status != 0) {
$this->rollbackTransaction();
return -2;
}
}

if (trim($comment) != '' ) {
$status = $this->setComment('DATABASE', $dbName, '', $comment);
Expand Down

0 comments on commit 2d92e82

Please sign in to comment.