mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 05:02:36 +01:00
Prevent setup from overwriting exisitng database
This commit is contained in:
parent
eed29c0180
commit
58d1378a10
@ -122,6 +122,10 @@ class AppController extends BaseController
|
||||
fwrite($fp, $config);
|
||||
fclose($fp);
|
||||
|
||||
if (Utils::isDatabaseSetup()) {
|
||||
return Redirect::to('/login');
|
||||
}
|
||||
|
||||
// == DB Migrate & Seed == //
|
||||
$sqlFile = base_path() . '/database/setup.sql';
|
||||
DB::unprepared(file_get_contents($sqlFile));
|
||||
|
Loading…
Reference in New Issue
Block a user