fixed a bug in interval adjustment