root 5 năm trước cách đây
mục cha
commit
c7f560551c

+ 3 - 0
app/Console/Commands/V2boardInit.php

@@ -38,6 +38,9 @@ class V2boardInit extends Command
      */
     public function handle()
     {
+        \Artisan::call('key:generate');
+        \Artisan::call('config:cache');
+    	DB::connection()->getPdo();
     	$file = \File::get(base_path() . '/install.sql');
     	if (!$file) {
     		abort(500, '数据库文件不存在');

+ 2 - 0
app/Console/Commands/V2boardUpdate.php

@@ -38,6 +38,8 @@ class V2boardUpdate extends Command
      */
     public function handle()
     {
+        \Artisan::call('config:cache');
+    	DB::connection()->getPdo();
     	$file = \File::get(base_path() . '/update.sql');
     	if (!$file) {
     		abort(500, '数据库文件不存在');