Removed endless loop when opening tab pairs.