Fix bug with checking version