cleaned up comments and fmt'd code