bug fix in lattice file