Prevent simultaneous refreshes when restoring auth info (#7835)
* Prevent multiple simultaneos refreshes when retrieving auth info * Add changeset * refactor
This commit is contained in:
1 parent
74808431e5
commit
2ffdc50ea1
2 files changed
+11
No files matched your search
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"claude-dev": patch
|
||||
---
|
||||
|
||||
Prevent simultaneuos refreshes when restoring auth info
|
||||
@@ -351,6 +351,12 @@ export class AuthService {
|
||||
throw new Error("Auth provider is not set")
|
||||
}
|
||||
|
||||
// If a refresh is already in progress, wait for it to complete
|
||||
if (this._refreshPromise) {
|
||||
Logger.info("Token refresh already in progress, waiting for completion")
|
||||
await this._refreshPromise
|
||||
}
|
||||
|
||||
return this._provider.retrieveClineAuthInfo(this._controller)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user