chore: inspect staged changes for commit message

This commit is contained in:
Andras Bacsai
2026-06-04 15:24:53 +02:00
parent 981b670eb4
commit 22f9f96db6
16 changed files with 1071 additions and 142 deletions
+8 -8
View File
@@ -1057,7 +1057,6 @@ function sslip(Server $server)
function get_service_templates(bool $force = false): Collection
{
if ($force) {
try {
$response = Http::retry(3, 1000)->get(config('constants.services.official'));
@@ -1068,15 +1067,16 @@ function get_service_templates(bool $force = false): Collection
return collect($services);
} catch (Throwable) {
$services = File::get(base_path('templates/'.config('constants.services.file_name')));
return collect(json_decode($services))->sortKeys();
return get_service_templates();
}
} else {
$services = File::get(base_path('templates/'.config('constants.services.file_name')));
return collect(json_decode($services))->sortKeys();
}
$path = base_path('templates/'.config('constants.services.file_name'));
$mtime = filemtime($path) ?: 0;
return Cache::remember("service-templates:{$mtime}", now()->addDay(), function () use ($path) {
return collect(json_decode(File::get($path)))->sortKeys();
});
}
function getResourceByUuid(string $uuid, ?int $teamId = null)