cleaned up documentation to reflect recent refactoring; also removed
more unnecessary undefs