From f3949569c875354789f8ce426a8d2e01cdbaa65d Mon Sep 17 00:00:00 2001 From: Hailey Date: Sun, 31 Aug 2025 13:28:49 -0700 Subject: [PATCH] rm --- src/env/helper.ts | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 src/env/helper.ts diff --git a/src/env/helper.ts b/src/env/helper.ts deleted file mode 100644 index 25e934151f..0000000000 --- a/src/env/helper.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Validates a proxy header is valid if supplied - */ -export const isValidProxyHeaderOrThrow = (val: string) => { - if (!val) { - return - } - - if (!val.startsWith('did:')) { - throw new Error( - 'Configured proxy header is invalid. Does not start with `did:`', - ) - } - - const pts = val.split('#') - if (pts.length !== 2) { - throw new Error( - 'Configured proxy header is invalid. Does not contain a single `#`', - ) - } - - if (pts[1].length < 1) { - throw new Error( - 'Configured proxy header is invalid. Does not contain a valid service after the `#`', - ) - } -}