Skip to content

Commit

Permalink
Added support for a schema array to PostgresBuilder (#15535)
Browse files Browse the repository at this point in the history
  • Loading branch information
dcro authored and taylorotwell committed Sep 21, 2016
1 parent d122972 commit f0266cb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Illuminate/Database/Schema/PostgresBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit f0266cb

Please sign in to comment.