Map removePropFromMap(Map o, String prop) { Map obj = {...o}; obj.remove(prop); return o; }