Minor bug fix

Solved the problem causing unexpected end of file error.