From 327f556a0331aeea4d79b35e0ccc662ebe3066cc Mon Sep 17 00:00:00 2001 From: Adam Naji <110662505+Bashamega@users.noreply.github.com> Date: Sat, 10 Jan 2026 10:08:56 +0200 Subject: [PATCH] Potential fix for code scanning alert no. 4: Prototype-polluting function Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --- src/build/helpers.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/build/helpers.ts b/src/build/helpers.ts index 4a211d4ae..0122313ae 100644 --- a/src/build/helpers.ts +++ b/src/build/helpers.ts @@ -134,6 +134,9 @@ export function merge( throw new Error("Either `target` or `src` is null"); } for (const k in src) { + if (k === "__proto__" || k === "constructor" || k === "prototype") { + continue; + } if (Object.getOwnPropertyDescriptor(src, k)) { if (Object.getOwnPropertyDescriptor(target, k)) { const targetProp = target[k];