mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-15 00:15:15 +08:00
Fix build
This commit is contained in:
@@ -31,6 +31,7 @@ namespace MQTTnet.Client
|
||||
}
|
||||
|
||||
#if !NETSTANDARD1_3
|
||||
#if !WINDOWS_UWP
|
||||
/// <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.
|
||||
@@ -42,6 +43,13 @@ namespace MQTTnet.Client
|
||||
/// This is not related to the credentials which are used for the MQTT protocol.
|
||||
/// </summary>
|
||||
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
|
||||
}
|
||||
}
|
||||
@@ -218,9 +218,11 @@ namespace MQTTnet.Implementations
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#if !NETSTANDARD1_3
|
||||
#if !WINDOWS_UWP
|
||||
clientWebSocket.Options.UseDefaultCredentials = _options.UseDefaultCredentials;
|
||||
#endif
|
||||
clientWebSocket.Options.KeepAliveInterval = _options.KeepAliveInterval;
|
||||
#endif
|
||||
clientWebSocket.Options.Credentials = _options.Credentials;
|
||||
|
||||
Reference in New Issue
Block a user