chore: improve logout behavior (#118)

* resubscribe on logout

* .

* .
This commit is contained in:
reya
2025-08-10 10:43:28 +07:00
committed by GitHub
parent 5011becacb
commit ca622d1262
5 changed files with 95 additions and 88 deletions

View File

@@ -54,9 +54,9 @@ pub fn nostr_client() -> &'static Client {
.gossip(true)
.automatic_authentication(true)
.verify_subscriptions(false)
// Sleep after idle for 20 seconds
// Sleep after idle for 30 seconds
.sleep_when_idle(SleepWhenIdle::Enabled {
timeout: Duration::from_secs(20),
timeout: Duration::from_secs(30),
});
ClientBuilder::default().database(lmdb).opts(opts).build()