fixed a logical bug