ErisApps / CatCore

A shared high-performance chat client library written in .NET Standard 2.0
GNU General Public License v3.0
29 stars 3 forks source link

Deferred async token refresh at startup #29

Closed ErisApps closed 2 years ago

ErisApps commented 2 years ago

This PR resolves the main thread blocking token refresh by making it deferred and off-thread. New exception types TwitchNotAuthenticatedException with base NotAuthenticatedException were also introduced to more transparantly communicate to consumers that certain features aren't available (yet).

This PR affects the suite of Twitch modules/services as it basically affects the shared initialization logic for said platform:

It's considered stable as far as my testing goes though.