refactored catalog uploading