Tidied up what I've done so far