refactor(channels): centralize match metadata

This commit is contained in:
Peter Steinberger
2026-01-21 18:21:19 +00:00
parent b52ab96e2c
commit 88d76d4be5
11 changed files with 73 additions and 38 deletions

View File

@@ -16,6 +16,8 @@ export type AllowlistMatch<TSource extends string = AllowlistMatchSource> = {
matchSource?: TSource;
};
export function formatAllowlistMatchMeta(match?: AllowlistMatch | null): string {
export function formatAllowlistMatchMeta(
match?: { matchKey?: string; matchSource?: string } | null,
): string {
return `matchKey=${match?.matchKey ?? "none"} matchSource=${match?.matchSource ?? "none"}`;
}