Tidied up code using formatR