We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0ca97fa + c3d3464 commit 2772fa8Copy full SHA for 2772fa8
src/Illuminate/Database/Schema/SQLiteBuilder.php
@@ -10,6 +10,24 @@ class SQLiteBuilder extends Builder
10
* @return void
11
*/
12
public function dropAllTables()
13
+ {
14
+ if ($this->connection->getDatabaseName() != ':memory:') {
15
+ return $this->refreshDatabaseFile();
16
+ }
17
+
18
+ $this->connection->select($this->grammar->compileEnableWriteableSchema());
19
20
+ $this->connection->select($this->grammar->compileDropAllTables());
21
22
+ $this->connection->select($this->grammar->compileDisableWriteableSchema());
23
24
25
+ /**
26
+ * Delete the database file & re-create it.
27
+ *
28
+ * @return void
29
+ */
30
+ public function refreshDatabaseFile()
31
{
32
unlink($this->connection->getDatabaseName());
33
0 commit comments