ÿØÿà JPEG ÿþ;
Server IP : 68.65.120.201 / Your IP : 216.73.216.135 Web Server : LiteSpeed System : Linux server179.web-hosting.com 4.18.0-513.18.1.lve.el8.x86_64 #1 SMP Thu Feb 22 12:55:50 UTC 2024 x86_64 User : taxhyuvu ( 2294) PHP Version : 8.1.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/taxhyuvu/nodevenv/public_html/dp_taxhelplines/14/lib/node_modules/@hapi/hoek/lib/ |
Upload File : |
'use strict'; const Assert = require('./assert'); const Clone = require('./clone'); const Utils = require('./utils'); const internals = {}; module.exports = internals.merge = function (target, source, options) { Assert(target && typeof target === 'object', 'Invalid target value: must be an object'); Assert(source === null || source === undefined || typeof source === 'object', 'Invalid source value: must be null, undefined, or an object'); if (!source) { return target; } options = Object.assign({ nullOverride: true, mergeArrays: true }, options); if (Array.isArray(source)) { Assert(Array.isArray(target), 'Cannot merge array onto an object'); if (!options.mergeArrays) { target.length = 0; // Must not change target assignment } for (let i = 0; i < source.length; ++i) { target.push(Clone(source[i], { symbols: options.symbols })); } return target; } const keys = Utils.keys(source, options); for (let i = 0; i < keys.length; ++i) { const key = keys[i]; if (key === '__proto__' || !Object.prototype.propertyIsEnumerable.call(source, key)) { continue; } const value = source[key]; if (value && typeof value === 'object') { if (target[key] === value) { continue; // Can occur for shallow merges } if (!target[key] || typeof target[key] !== 'object' || (Array.isArray(target[key]) !== Array.isArray(value)) || value instanceof Date || (Buffer && Buffer.isBuffer(value)) || // $lab:coverage:ignore$ value instanceof RegExp) { target[key] = Clone(value, { symbols: options.symbols }); } else { internals.merge(target[key], value, options); } } else { if (value !== null && value !== undefined) { // Explicit to preserve empty strings target[key] = value; } else if (options.nullOverride) { target[key] = value; } } } return target; };