mirror of
https://github.com/tiennm99/coolify.git
synced 2026-10-03 04:46:18 +00:00
fix
This commit is contained in:
1 parent
7456fc1ac7
commit
3589b92ec9
84 files changed
+285
-244
No files matched your search
@@ -10,12 +10,13 @@ class Upgrade extends Component
|
||||
{
|
||||
public bool $showProgress = false;
|
||||
public bool $isUpgradeAvailable = false;
|
||||
public string $latestVersion = '';
|
||||
|
||||
public function checkUpdate()
|
||||
{
|
||||
$latestVersion = get_latest_version_of_coolify();
|
||||
$this->latestVersion = get_latest_version_of_coolify();
|
||||
$currentVersion = config('version');
|
||||
version_compare($currentVersion, $latestVersion, '<') ? $this->isUpgradeAvailable = true : $this->isUpgradeAvailable = false;
|
||||
version_compare($currentVersion, $this->latestVersion, '<') ? $this->isUpgradeAvailable = true : $this->isUpgradeAvailable = false;
|
||||
if (isDev()) {
|
||||
$this->isUpgradeAvailable = true;
|
||||
}
|
||||
@@ -25,7 +26,7 @@ class Upgrade extends Component
|
||||
try {
|
||||
$this->showProgress = true;
|
||||
resolve(UpdateCoolify::class)(true);
|
||||
Toaster::success('Upgrading Coolify to latest version...');
|
||||
Toaster::success("Upgrading Coolify to {$this->latestVersion} version...");
|
||||
} catch (\Exception $e) {
|
||||
return general_error_handler(err: $e, that: $this);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user