disable model caching during install/update

This commit is contained in:
denisdulici
2020-02-07 14:37:22 +03:00
parent 18b1e6e703
commit 293c9ec8f2
7 changed files with 18 additions and 6 deletions

View File

@ -62,6 +62,9 @@ class FinishUpdate extends Command
session(['company_id' => $company_id]);
setting()->setExtraColumns(['company_id' => $company_id]);
// Disable model cache during update
config(['laravel-model-caching.enabled' => false]);
event(new UpdateFinished($alias, $new, $old));
}
}

View File

@ -994,6 +994,7 @@ class Version200 extends Listener
'QUEUE_CONNECTION' => 'sync',
'LOG_CHANNEL' => 'stack',
'FIREWALL_ENABLED' => 'true',
'MODEL_CACHE_ENABLED' => 'true',
]);
}
}

View File

@ -254,10 +254,11 @@ class Installer
{
// Update .env file
static::updateEnv([
'APP_LOCALE' => session('locale'),
'APP_INSTALLED' => 'true',
'APP_DEBUG' => 'false',
'FIREWALL_ENABLED' => 'true',
'APP_LOCALE' => session('locale'),
'APP_INSTALLED' => 'true',
'APP_DEBUG' => 'false',
'FIREWALL_ENABLED' => 'true',
'MODEL_CACHE_ENABLED' => 'true',
]);
// Rename the robots.txt file