Fix typo

While I'm here clean the code.