Fix upload of files (by adding a couple of missing imports)