mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-31 03:02:39 +08:00
Fix build
This commit is contained in:
@@ -31,6 +31,7 @@ namespace MQTTnet.Client
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if !NETSTANDARD1_3
|
#if !NETSTANDARD1_3
|
||||||
|
#if !WINDOWS_UWP
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the keep alive interval for the Web Socket connection.
|
/// Gets or sets the keep alive interval for the Web Socket connection.
|
||||||
/// This is not related to the keep alive interval for the MQTT protocol.
|
/// This is not related to the keep alive interval for the MQTT protocol.
|
||||||
@@ -42,6 +43,13 @@ namespace MQTTnet.Client
|
|||||||
/// This is not related to the credentials which are used for the MQTT protocol.
|
/// This is not related to the credentials which are used for the MQTT protocol.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool UseDefaultCredentials { get; set; }
|
public bool UseDefaultCredentials { get; set; }
|
||||||
|
#else
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the keep alive interval for the Web Socket connection.
|
||||||
|
/// This is not related to the keep alive interval for the MQTT protocol.
|
||||||
|
/// </summary>
|
||||||
|
public TimeSpan KeepAliveInterval { get; set; } = TimeSpan.FromSeconds(30);
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -220,7 +220,9 @@ namespace MQTTnet.Implementations
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if !NETSTANDARD1_3
|
#if !NETSTANDARD1_3
|
||||||
|
#if !WINDOWS_UWP
|
||||||
clientWebSocket.Options.UseDefaultCredentials = _options.UseDefaultCredentials;
|
clientWebSocket.Options.UseDefaultCredentials = _options.UseDefaultCredentials;
|
||||||
|
#endif
|
||||||
clientWebSocket.Options.KeepAliveInterval = _options.KeepAliveInterval;
|
clientWebSocket.Options.KeepAliveInterval = _options.KeepAliveInterval;
|
||||||
#endif
|
#endif
|
||||||
clientWebSocket.Options.Credentials = _options.Credentials;
|
clientWebSocket.Options.Credentials = _options.Credentials;
|
||||||
|
|||||||
Reference in New Issue
Block a user