Remove unused code
Fixed a minor typo in doc