fix occasional errors