Added handling for malformed objects and actions.