Removed bad if statements and made changes to the upload script