Set the project path is the represented file path if undefined for item

This prevents exceptions on the browser process from passing a null
argument over IPC.