Prettify code, removed useless stuff