bug fix for NPE in string conversion.