Tidying up the code!