js how to remove a property from an object if exists code example
Example 1: nodejs delete object key
delete obj.firstname;
Example 2: javascript remove object element
delete object.element;
delete obj.firstname;
delete object.element;