Tidy up related to metadata cursors.