From f6d584cf99abdb292985f812e64553a37ab51a01 Mon Sep 17 00:00:00 2001 From: Jacob Nguyen <76754747+jacoobes@users.noreply.github.com> Date: Sun, 15 May 2022 16:04:58 -0500 Subject: [PATCH] feat: delete partition.ts --- src/handler/utilities/partition.ts | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 src/handler/utilities/partition.ts diff --git a/src/handler/utilities/partition.ts b/src/handler/utilities/partition.ts deleted file mode 100644 index f83c1c0..0000000 --- a/src/handler/utilities/partition.ts +++ /dev/null @@ -1,8 +0,0 @@ -export function partition(condition: (el: T) => el is U, array: T[]): [U[], T[]] { - const uArr: U[] = []; - const vArr: T[] = []; - for (const el of array) { - (condition(el) ? uArr : vArr).push(el); - } - return [uArr, vArr]; -}