fixes open file bug
Merge pull request #111 from bhattigurjot/master

fixes open file bug