Even tidier version with unecessary imports removed