resolve bug about authorization fail when uploading