I am trying to remove all the items from a list except "Red" on a specific condition by using remove(), but when I debug, it gives error:
"Accessing the 'arguments' property of a function is not allowed in strict mode".
Is there a alternative for remove that I can use in this situation. Below is the code that I am using:
for (var k = 0; k < homeCtrl.List.length; k++) {
if (homeCtrl.ColorList[k].name != 'Red') {
homeCtrl.ColorList.remove[k];
}
}