Fix a bug in LocalChannel