fix infinite dash bug