Fix makeOverlayPositions race condition error