File tree Expand file tree Collapse file tree 1 file changed +11
-8
lines changed
Expand file tree Collapse file tree 1 file changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -238,16 +238,19 @@ protected function bootDatabaseForErrors()
238238 return ;
239239 }
240240
241- if (Schema::connection ('redirect-sqlite ' )->hasTable ('errors ' )) {
242- return ;
243- }
244-
245241 $ defaultConnection = DB ::getDefaultConnection ();
246242 DB ::setDefaultConnection ('redirect-sqlite ' );
247- require_once (__DIR__ . '/../database/migrations/create_redirect_error_tables.php.stub ' );
248- (new \CreateRedirectErrorTables ())->up ();
249- require_once (__DIR__ . '/../database/migrations/increase_redirect_error_table_url_length.php.stub ' );
250- (new \IncreaseRedirectErrorTableUrlLength ())->up ();
243+
244+ if (! Schema::connection ('redirect-sqlite ' )->hasTable ('errors ' )) {
245+ require_once (__DIR__ . '/../database/migrations/create_redirect_error_tables.php.stub ' );
246+ (new \CreateRedirectErrorTables ())->up ();
247+ }
248+
249+ if (! Schema::connection ('redirect-sqlite ' )->hasColumn ('errors ' , 'url_md5 ' )) {
250+ require_once (__DIR__ . '/../database/migrations/increase_redirect_error_table_url_length.php.stub ' );
251+ (new \IncreaseRedirectErrorTableUrlLength ())->up ();
252+ }
253+
251254 DB ::setDefaultConnection ($ defaultConnection );
252255 }
253256
You can’t perform that action at this time.
0 commit comments