我有以下密码:
for (i in awards) {
if (awards[i] instanceof Array === false) {
console.log(awards[i]);
httpFactory.patch(awards[i], {"read": true}, false);
}
}
My IDE shows this error relating to the code above:
对意外(自定义/继承)成员进行可能的迭代, 可能丢失了一张“拥有财产”的支票
Checks for any instances of unfiltered for-in loops in JavaScript. The 使用此构造会导致处理继承的或意外的 您需要使用 hasOwnProperty ()筛选自己的属性 验证工作在 JavaScript、 html 或 jsp 文件中。
你能更详细地解释一下这句话的意思吗?