You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 2, 2022. It is now read-only.
bot.onClientInitalization ={(client:Client) in
DispatchQueue.main.async(execute:{
client.messageEventsDelegate =self
client.connectionEventsDelegate =self//send client to object cache? //put client somewhere to use it again elsewhere or// try another design?})
or should i really be doing webAPI stuff here...
func connected(_ client:Client){print("\(client.connected)\("connected FromForeground")")//send client to object cache? //put client somewhere to use it again elsewhere or// try another design?}
I see there's a few ways to get the initialized client object so that I can call WebAPI.
But how can I pass this object around the app and use it anywhere in the app?
Or is it cool to just do initialization again anywhere when I need the client object?
The text was updated successfully, but these errors were encountered:
or should i really be doing webAPI stuff here...
I see there's a few ways to get the initialized client object so that I can call WebAPI.
But how can I pass this object around the app and use it anywhere in the app?
Or is it cool to just do initialization again anywhere when I need the client object?
The text was updated successfully, but these errors were encountered: