Fixed error when location parameter is blank.