Removed unused variable in parser. Added bool ok to check if file is opened correctly