File tree Expand file tree Collapse file tree 2 files changed +9
-8
lines changed
src/Illuminate/Database/Schema Expand file tree Collapse file tree 2 files changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -162,7 +162,7 @@ public function hasTable($table)
162
162
{
163
163
$ table = $ this ->connection ->getTablePrefix ().$ table ;
164
164
165
- foreach ($ this ->getTables () as $ value ) {
165
+ foreach ($ this ->getTables (false ) as $ value ) {
166
166
if (strtolower ($ table ) === strtolower ($ value ['name ' ])) {
167
167
return true ;
168
168
}
Original file line number Diff line number Diff line change @@ -34,16 +34,17 @@ public function dropDatabaseIfExists($name)
34
34
/**
35
35
* Get the tables for the database.
36
36
*
37
+ * @param bool $withSize
37
38
* @return array
38
39
*/
39
- public function getTables ()
40
+ public function getTables ($ withSize = true )
40
41
{
41
- $ withSize = false ;
42
-
43
- try {
44
- $ withSize = $ this -> connection -> scalar ( $ this -> grammar -> compileDbstatExists ());
45
- } catch ( QueryException $ e ) {
46
- //
42
+ if ( $ withSize) {
43
+ try {
44
+ $ withSize = $ this -> connection -> scalar ( $ this -> grammar -> compileDbstatExists ());
45
+ } catch ( QueryException $ e ) {
46
+ $ withSize = false ;
47
+ }
47
48
}
48
49
49
50
return $ this ->connection ->getPostProcessor ()->processTables (
You can’t perform that action at this time.
0 commit comments