Refactor a little bit
Correct an error message