I have this little function that is supposed to remove object properties with even values.
function removeEvenValues(obj) {
Object.keys(obj).forEach(k => ((!isNaN(obj[k])) && (obj[k] % 2 === 0)) ? delete obj[k] : k);
}
In the else {} part of the ternary operator, how do I leave it empty like in an if (true){ doSomething();}
kind of construct? Or does it even make sense to use a fat arrow function in this case?