few typo fixes and npe in parse-time