mirror of
https://gitee.com/lyt-top/vue-next-admin
synced 2026-06-06 02:38:39 +08:00
'admin-22.06.07:函数deepClone对null的判断错误'
This commit is contained in:
@ -106,7 +106,7 @@ export function deepClone(obj: any) {
|
||||
newObj = {};
|
||||
}
|
||||
for (let attr in obj) {
|
||||
if (typeof obj[attr] === 'object') {
|
||||
if (obj[attr] && typeof obj[attr] === 'object') {
|
||||
newObj[attr] = deepClone(obj[attr]);
|
||||
} else {
|
||||
newObj[attr] = obj[attr];
|
||||
|
||||
Reference in New Issue
Block a user