Tidied code.