removed useless code, changed for style.