fix($location): don't call toString on null values