fix loop break