remove global legend object