Fixes race condition when saving projects with file belonging to another
owner.