Skip to content

OnClientDataReceived is null, How to fix this #14

@nagasuki

Description

@nagasuki
private void SetupDefaultCallbacks()
        {
            if (OnServerConnected == null)
            {
                OnServerConnected = (connId) => UtpLog.Warning("OnServerConnected called with no handler");
            }
            if (OnServerDisconnected == null)
            {
                OnServerDisconnected = (connId) => UtpLog.Warning("OnServerDisconnected called with no handler");
            }
            if (OnServerDataReceived == null)
            {
                OnServerDataReceived = (connId, data, channel) => UtpLog.Warning("OnServerDataReceived called with no handler");
            }
            if (OnClientConnected == null)
            {
                OnClientConnected = () => UtpLog.Warning("OnClientConnected called with no handler");
            }
            if (OnClientDisconnected == null)
            {
                OnClientDisconnected = () => UtpLog.Warning("OnClientDisconnected called with no handler");
            }
            if (OnClientDataReceived == null)
            {
                OnClientDataReceived = (data, channel) => UtpLog.Warning("OnClientDataReceived called with no handler");
            }
        }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions