Metadata document fixes