style: auto-fix lint and format

This commit is contained in:
ajnart authored and github-actions[bot] committed 2026-06-27 11:04:33 +00:00
1 parent e687bc8c92
commit a56bf0f32d
1 file changed
+21 -22
@@ -153,7 +153,11 @@ const getGithubReleaseAsync = async (
const api = getGithubApi(baseUrl, "Homarr-Lab/Homarr:GithubReleaseProvider", token); const api = getGithubApi(baseUrl, "Homarr-Lab/Homarr:GithubReleaseProvider", token);
try { try {
const allReleases = await api.paginate(api.rest.repos.listReleases, { owner: parsed.owner, repo: parsed.name, per_page: 100 }); const allReleases = await api.paginate(api.rest.repos.listReleases, {
owner: parsed.owner,
repo: parsed.name,
per_page: 100,
});
if (allReleases.length === 0) { if (allReleases.length === 0) {
return { success: false, error: { code: "noReleasesFound", message: `${identifier} has no GitHub releases` } }; return { success: false, error: { code: "noReleasesFound", message: `${identifier} has no GitHub releases` } };
} }
@@ -298,10 +302,9 @@ const getGitHubContainerRegistryTokenAsync = async (registryUrl: URL, repository
}; };
const getGitHubContainerRegistryTagsAsync = async (registryUrl: URL, repositoryName: string, token: string) => { const getGitHubContainerRegistryTagsAsync = async (registryUrl: URL, repositoryName: string, token: string) => {
const response = await fetchProvider( const response = await fetchProvider(buildUrl(registryUrl.origin, `/v2/${repositoryName}/tags/list`), {
buildUrl(registryUrl.origin, `/v2/${repositoryName}/tags/list`), headers: { Authorization: `Bearer ${token}` },
{ headers: { Authorization: `Bearer ${token}` } }, });
);
if (!response.ok) throw new Error(response.statusText); if (!response.ok) throw new Error(response.statusText);
const result = gitHubContainerRegistryTagsSchema.safeParse(await response.json()); const result = gitHubContainerRegistryTagsSchema.safeParse(await response.json());
@@ -328,10 +331,9 @@ const getGitHubContainerRegistryTagCreatedAtAsync = async (
const configDigest = imageManifest.config?.digest; const configDigest = imageManifest.config?.digest;
if (!configDigest) throw new Error("Missing image config digest"); if (!configDigest) throw new Error("Missing image config digest");
const response = await fetchProvider( const response = await fetchProvider(buildUrl(registryUrl.origin, `/v2/${repositoryName}/blobs/${configDigest}`), {
buildUrl(registryUrl.origin, `/v2/${repositoryName}/blobs/${configDigest}`), headers: { Authorization: `Bearer ${token}` },
{ headers: { Authorization: `Bearer ${token}` } }, });
);
if (!response.ok) throw new Error(response.statusText); if (!response.ok) throw new Error(response.statusText);
const result = gitHubContainerRegistryConfigSchema.safeParse(await response.json()); const result = gitHubContainerRegistryConfigSchema.safeParse(await response.json());
@@ -348,20 +350,17 @@ const getGitHubContainerRegistryManifestAsync = async (
) => { ) => {
if (!reference) throw new Error("Missing image manifest reference"); if (!reference) throw new Error("Missing image manifest reference");
const response = await fetchProvider( const response = await fetchProvider(buildUrl(registryUrl.origin, `/v2/${repositoryName}/manifests/${reference}`), {
buildUrl(registryUrl.origin, `/v2/${repositoryName}/manifests/${reference}`), headers: {
{ Authorization: `Bearer ${token}`,
headers: { Accept: [
Authorization: `Bearer ${token}`, "application/vnd.oci.image.index.v1+json",
Accept: [ "application/vnd.docker.distribution.manifest.list.v2+json",
"application/vnd.oci.image.index.v1+json", "application/vnd.oci.image.manifest.v1+json",
"application/vnd.docker.distribution.manifest.list.v2+json", "application/vnd.docker.distribution.manifest.v2+json",
"application/vnd.oci.image.manifest.v1+json", ].join(", "),
"application/vnd.docker.distribution.manifest.v2+json",
].join(", "),
},
}, },
); });
if (!response.ok) throw new Error(response.statusText); if (!response.ok) throw new Error(response.statusText);
const result = gitHubContainerRegistryManifestSchema.safeParse(await response.json()); const result = gitHubContainerRegistryManifestSchema.safeParse(await response.json());