[misc] Fix UTF-8 error in 'restore_affiliations' script