mirror of
https://github.com/wiz0u/WTelegramClient.git
synced 2025-12-06 06:52:01 +01:00
Fix infinite recursion on Dispose after downloads (fix #274)
This commit is contained in:
parent
e5c6086e11
commit
a28b984395
2
.github/dev.yml
vendored
2
.github/dev.yml
vendored
|
|
@ -1,7 +1,7 @@
|
|||
pr: none
|
||||
trigger: [ master ]
|
||||
|
||||
name: 4.1.6-dev.$(Rev:r)
|
||||
name: 4.1.7-dev.$(Rev:r)
|
||||
|
||||
pool:
|
||||
vmImage: ubuntu-latest
|
||||
|
|
|
|||
|
|
@ -49,7 +49,8 @@ namespace WTelegram
|
|||
/// <summary>Size of chunks when uploading/downloading files. Reduce this if you don't have much memory</summary>
|
||||
public int FilePartSize { get; set; } = 512 * 1024;
|
||||
/// <summary>Is this Client instance the main or a secondary DC session</summary>
|
||||
public bool IsMainDC => (_dcSession?.DataCenter?.id - _session.MainDC) is null or 0;
|
||||
public bool IsMainDC => _dcSession?.DataCenter?.flags.HasFlag(DcOption.Flags.media_only) != true
|
||||
&& (_dcSession?.DataCenter?.id - _session.MainDC) is null or 0;
|
||||
/// <summary>Has this Client established connection been disconnected?</summary>
|
||||
public bool Disconnected => _tcpClient != null && !(_tcpClient.Client?.Connected ?? false);
|
||||
/// <summary>ID of the current logged-in user or 0</summary>
|
||||
|
|
|
|||
Loading…
Reference in a new issue