From f0266cbb0c5c5686ae5661c948fe39a21b6ab6be Mon Sep 17 00:00:00 2001 From: Dan Cotora Date: Wed, 21 Sep 2016 22:33:30 +0300 Subject: [PATCH] Added support for a schema array to PostgresBuilder (#15535) --- src/Illuminate/Database/Schema/PostgresBuilder.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Illuminate/Database/Schema/PostgresBuilder.php b/src/Illuminate/Database/Schema/PostgresBuilder.php index 20abc0fe1e48..31102b742a2f 100755 --- a/src/Illuminate/Database/Schema/PostgresBuilder.php +++ b/src/Illuminate/Database/Schema/PostgresBuilder.php @@ -16,6 +16,10 @@ public function hasTable($table) $schema = $this->connection->getConfig('schema'); + if (is_array($schema)) { + $schema = head($schema); + } + $table = $this->connection->getTablePrefix().$table; return count($this->connection->select($sql, [$schema, $table])) > 0;