some fixes that I did in 2d