It makes sense to check the file mime-type of the file somewhere here.