Refactored reading board from file.