mirror of
https://github.com/sochix/TLSharp.git
synced 2025-12-06 08:02:00 +01:00
Merge pull request #269 from aarani/patch-1
Change TLDialogs to TLAbsDialogs
This commit is contained in:
commit
263685f050
|
|
@ -196,10 +196,10 @@ namespace TLSharp.Core
|
|||
return await SendRequestAsync<Boolean>(req);
|
||||
}
|
||||
|
||||
public async Task<TLDialogs> GetUserDialogsAsync()
|
||||
public async Task<TLAbsDialogs> GetUserDialogsAsync()
|
||||
{
|
||||
var peer = new TLInputPeerSelf();
|
||||
return await SendRequestAsync<TLDialogs>(
|
||||
return await SendRequestAsync<TLAbsDialogs>(
|
||||
new TLRequestGetDialogs() { offset_date = 0, offset_peer = peer, limit = 100 });
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ namespace TLSharp.Tests
|
|||
|
||||
await client.ConnectAsync();
|
||||
|
||||
var dialogs = await client.GetUserDialogsAsync();
|
||||
var dialogs = (TLDialogs) await client.GetUserDialogsAsync();
|
||||
var chat = dialogs.chats.lists
|
||||
.Where(c => c.GetType() == typeof(TLChannel))
|
||||
.Cast<TLChannel>()
|
||||
|
|
|
|||
Loading…
Reference in a new issue