属性没有 select 时 调用 .toJSON() 不应该 logger warning
chenhui5416 opened this issue · comments
Lance commented
属性没有 select 时 调用 .toJSON() 不应该 logger warning
Chen Yangjian commented
toJSON() {
const obj = {};
for (const key in this) {
if (this.#rawUnset.has(key)) continue;
if (typeof this[key] !== 'function') {
const value = this[key];
if (value != null) {
obj[key] = value instanceof Bone ? value.toJSON() : value;
}
}
}
return obj;
}
看代码已经会跳过未 select 的属性,需要再看一下具体问题是啥
Chen Yangjian commented
之前没有复现问题,unset attribute warning 也已经全局移除