mirror of
https://github.com/Yanyutin753/ChatGPT-Next-Web-LangChain-Gpt-4-All.git
synced 2025-10-15 15:41:23 +00:00
10 lines
275 B
TypeScript
10 lines
275 B
TypeScript
export function merge(target: any, source: any) {
|
|
Object.keys(source).forEach(function (key) {
|
|
if (source[key] && typeof source[key] === "object") {
|
|
merge((target[key] = target[key] || {}), source[key]);
|
|
return;
|
|
}
|
|
target[key] = source[key];
|
|
});
|
|
}
|