mirror of
https://github.com/status-im/status-desktop.git
synced 2025-02-18 01:27:25 +00:00
chore: update status-go version and update mailservers api
This commit is contained in:
parent
5327b7feea
commit
98b3e64573
@ -184,16 +184,20 @@ proc requestMessages*(self: MailserverModel, topics: seq[string], fromValue: int
|
|||||||
proc getMailserverTopics*(self: MailserverModel): seq[MailserverTopic] =
|
proc getMailserverTopics*(self: MailserverModel): seq[MailserverTopic] =
|
||||||
let response = status_mailservers.getMailserverTopics()
|
let response = status_mailservers.getMailserverTopics()
|
||||||
let topics = parseJson(response)["result"]
|
let topics = parseJson(response)["result"]
|
||||||
|
var newTopic: MailserverTopic
|
||||||
result = @[]
|
result = @[]
|
||||||
if topics.kind != JNull:
|
if topics.kind != JNull:
|
||||||
for topic in topics:
|
for topic in topics:
|
||||||
result.add(MailserverTopic(
|
newTopic = MailserverTopic(
|
||||||
topic: topic["topic"].getStr,
|
topic: topic["topic"].getStr,
|
||||||
discovery: topic["discovery?"].getBool,
|
discovery: topic["discovery?"].getBool,
|
||||||
negotiated: topic["negotiated?"].getBool,
|
negotiated: topic["negotiated?"].getBool,
|
||||||
chatIds: topic["chat-ids"].to(seq[string]),
|
|
||||||
lastRequest: topic["last-request"].getInt
|
lastRequest: topic["last-request"].getInt
|
||||||
))
|
)
|
||||||
|
if (topic["chat-ids"].kind != JNull):
|
||||||
|
newTopic.chatIds = topic["chat-ids"].to(seq[string])
|
||||||
|
|
||||||
|
result.add(newTopic)
|
||||||
|
|
||||||
|
|
||||||
proc getMailserverTopicsByChatId*(self: MailserverModel, chatId: string): seq[MailServerTopic] =
|
proc getMailserverTopicsByChatId*(self: MailserverModel, chatId: string): seq[MailServerTopic] =
|
||||||
|
2
vendor/status-go
vendored
2
vendor/status-go
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 46157dc4dc949690d66e047f451df1458a37ae23
|
Subproject commit 363ab0a2ab8dce98193c899c2c202cc885a45143
|
Loading…
x
Reference in New Issue
Block a user