Cleaning up the code

V0.2