Refactor instanceSettings() function for improved code readability

This commit is contained in:
Andras Bacsai
2024-10-01 10:37:40 +02:00
parent 4d9dcfb84c
commit 83549965ca
35 changed files with 47 additions and 65 deletions

View File

@@ -2,7 +2,6 @@
namespace App\Actions\Server;
use App\Models\InstanceSettings;
use App\Models\Server;
use Lorisleiva\Actions\Concerns\AsAction;
@@ -12,7 +11,7 @@ class CleanupDocker
public function handle(Server $server)
{
$settings = InstanceSettings::get();
$settings = instanceSettings();
$helperImageVersion = data_get($settings, 'helper_version');
$helperImage = config('coolify.helper_image');
$helperImageWithVersion = "$helperImage:$helperImageVersion";