fix difference bug