Compare commits

..

3 Commits

Author SHA1 Message Date
CZJCC df8f9d2dcd
Merge pull request #237 from Sunrisea/master-fix-login-bug
Fix bug of Inject security info
2025-07-17 19:08:17 +08:00
濯光 4600b89e45 fix bug of get_access_token 2025-07-17 19:00:22 +08:00
濯光 ce22e6a437 fix bug of get_access_token 2025-07-17 18:51:14 +08:00
1 changed files with 3 additions and 1 deletions

View File

@ -94,4 +94,6 @@ class NacosServerConnector:
async def inject_security_info(self, headers):
if self.client_config.username and self.client_config.password:
access_token = await self.auth_client.get_access_token(False)
headers[Constants.ACCESS_TOKEN] = access_token
if access_token is not None and access_token != "":
headers[Constants.ACCESS_TOKEN] = access_token
return