fix chart error when no data