more typos, removed unuseful code