Tidied code a little

Tidied code