Added cleanup of upload folder in case of rejected syncs + pep8