Fix lastBoundary