Fixed a few outstanding issues with uploading documents.