From 90125566bbaed8b5c6e55ca8dbc432e3433fb73c Mon Sep 17 00:00:00 2001 From: Maximilien Mellen Date: Wed, 19 Feb 2020 21:36:18 +0100 Subject: Enable TS strict mode by default (#3899) Fixes #3324 Co-authored-by: Kitson Kelly --- std/util/deep_assign.ts | 3 +++ 1 file changed, 3 insertions(+) (limited to 'std/util/deep_assign.ts') diff --git a/std/util/deep_assign.ts b/std/util/deep_assign.ts index 9b57e45dc..9034d89bd 100644 --- a/std/util/deep_assign.ts +++ b/std/util/deep_assign.ts @@ -1,4 +1,6 @@ // Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. +import { assert } from "../testing/asserts.ts"; + export function deepAssign( target: Record, ...sources: object[] @@ -24,6 +26,7 @@ export function deepAssign( if (typeof target[key] !== `object` || !target[key]) { target[key] = {}; } + assert(value); deepAssign(target[key] as Record, value); }); } -- cgit v1.2.3