From ec9dab11fad43c869c19cd3119a2ce516d7ae886 Mon Sep 17 00:00:00 2001 From: gevik Date: Sun, 9 Jun 2013 00:04:37 +0200 Subject: [PATCH] [1] Redone missing code. [2] Added empty line at the end of file [3] Removed exception. --- framework/yii/db/pgsql/Schema.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/framework/yii/db/pgsql/Schema.php b/framework/yii/db/pgsql/Schema.php index 66f0876..8cfb535 100644 --- a/framework/yii/db/pgsql/Schema.php +++ b/framework/yii/db/pgsql/Schema.php @@ -123,6 +123,8 @@ class Schema extends \yii\db\Schema if ($this->findColumns($table)) { $this->findConstraints($table); return $table; + } else { + return null; } } @@ -240,11 +242,7 @@ ORDER BY a.attnum; SQL; - try { - $columns = $this->db->createCommand($sql)->queryAll(); - } catch (\Exception $e) { - return false; - } + $columns = $this->db->createCommand($sql)->queryAll(); foreach ($columns as $column) { $column = $this->loadColumnSchema($column); $table->columns[$column->name] = $column; @@ -288,4 +286,4 @@ SQL; return $column; } -} \ No newline at end of file +}