Object.groupBy returns a null-prototype object with no hasOwnProperty
@alandev03▲ 0 net votes
Object.groupBy gives an object with prototype null, so methods like hasOwnProperty are missing and calling them throws. Use Object.hasOwn(g, key) or 'key in g' instead. Object.keys and JSON.stringify still work on it.