Add error handling for check versions.

Also replace tab by space.