merge: integrate dev branch (v1.56.0), resolve all conflicts
Resolves 15 conflicted files from dev merge: - Version bumps to v1.56.0, pnpm 10.32.0, turbo 2.8.15 - New integrations: tracearr (from dev) - New widgets: tracearr (from dev) - Updated dependencies: mysql2, typescript-eslint, isomorphic-dompurify - Keeps our custom server changes: esbuild, fastify, cron-job-api deps - Keeps our docker:test scripts and APPROACHES.md Co-authored-by: ajnart <49837342+ajnart@users.noreply.github.com>
This commit is contained in:
1 parent
deb9916d2d
commit
ed249ce7eb
74 files changed
+3449
-611
No files matched your search
@@ -41,6 +41,7 @@ import { ProwlarrIntegration } from "../prowlarr/prowlarr-integration";
|
||||
import { ProxmoxIntegration } from "../proxmox/proxmox-integration";
|
||||
import { QuayIntegration } from "../quay/quay-integration";
|
||||
import { SeerrIntegration } from "../seerr/seerr-integration";
|
||||
import { TracearrIntegration } from "../tracearr/tracearr-integration";
|
||||
import { TrueNasIntegration } from "../truenas/truenas-integration";
|
||||
import { UnifiControllerIntegration } from "../unifi-controller/unifi-controller-integration";
|
||||
import { UnraidIntegration } from "../unraid/unraid-integration";
|
||||
@@ -111,6 +112,7 @@ export const integrationCreators = {
|
||||
truenas: TrueNasIntegration,
|
||||
unraid: UnraidIntegration,
|
||||
coolify: CoolifyIntegration,
|
||||
tracearr: TracearrIntegration,
|
||||
glances: GlancesIntegration,
|
||||
immich: ImmichIntegration,
|
||||
} satisfies Record<IntegrationKind, IntegrationInstance | [(input: IntegrationInput) => Promise<Integration>]>;
|
||||
|
||||
@@ -58,24 +58,30 @@ export abstract class Integration {
|
||||
private createUrl(
|
||||
inputUrl: string,
|
||||
path: `/${string}`,
|
||||
queryParams?: Record<string, string | Date | number | boolean>,
|
||||
queryParams?: Record<string, string | Date | number | boolean | null | undefined>,
|
||||
) {
|
||||
const baseUrl = removeTrailingSlash(inputUrl);
|
||||
const url = new URL(`${baseUrl}${path}`);
|
||||
|
||||
if (queryParams) {
|
||||
for (const [key, value] of Object.entries(queryParams)) {
|
||||
if (value === null || value === undefined) {
|
||||
continue;
|
||||
}
|
||||
url.searchParams.set(key, value instanceof Date ? value.toISOString() : value.toString());
|
||||
}
|
||||
}
|
||||
|
||||
return url;
|
||||
}
|
||||
protected url(path: `/${string}`, queryParams?: Record<string, string | Date | number | boolean>) {
|
||||
protected url(path: `/${string}`, queryParams?: Record<string, string | Date | number | boolean | null | undefined>) {
|
||||
return this.createUrl(this.integration.url, path, queryParams);
|
||||
}
|
||||
|
||||
protected externalUrl(path: `/${string}`, queryParams?: Record<string, string | Date | number | boolean>) {
|
||||
protected externalUrl(
|
||||
path: `/${string}`,
|
||||
queryParams?: Record<string, string | Date | number | boolean | null | undefined>,
|
||||
) {
|
||||
return this.createUrl(this.integration.externalUrl ?? this.integration.url, path, queryParams);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user