Trim object names so they aren't quoted with spaces in them