Nicer code

But I'm not sure about the indentation