fixed deleteMetadata