Commented code, minor cleanup