We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 65f7a91 commit 359516aCopy full SHA for 359516a
lib/utils/object.ts
@@ -41,11 +41,7 @@ export function deepAssign(target: any, ...sources: any[]): any {
41
targetValue = null;
42
} else {
43
if (!targetValue) {
44
- if (sourceValue.constructor && sourceValue.constructor.prototype) {
45
- targetValue = Object.create(sourceValue.constructor.prototype);
46
- } else {
47
- targetValue = {};
48
- }
+ targetValue = Object.create(sourceValue.constructor.prototype);
49
}
50
deepAssign(targetValue, sourceValue);
51
0 commit comments