Fix changes for PR #104

*Fix typo
*Fix doc
*Fix some code