This message was deleted.
# ktor
s
This message was deleted.
u
Copy code
client.plugin(Auth).providers.filterIsInstance<BearerAuthProvider>()
                .firstOrNull()?.clearToken()
okay internet told me this, but feels a bit hacky. Is this really preferred way, or should I just let the instance get GCed?
h
That's how we currently handle it in our product, but we're interested in learning if there's a more elegant solution.
u
the explicit clear?
h
Yeah
👍 1
e
I think we can wrap this into extension. Could you log an issue or propose a PR?