update setLocation method to use the correct spec params (fix #3229)