safely return undefined if initial object is undefined