mirror of
https://github.com/YuWanTingbb/unofficial-gpt4.git
synced 2025-10-13 21:51:23 +00:00
修改异常报错
This commit is contained in:
@@ -720,7 +720,7 @@ public class chatController {
|
||||
if (resp.code() == 429) {
|
||||
return new ResponseEntity<>(Result.error("rate limit exceeded"), HttpStatus.TOO_MANY_REQUESTS);
|
||||
} else {
|
||||
String token = getSelfToken(apiKey);
|
||||
String token = getCopilotToken(apiKey);
|
||||
if (token == null) {
|
||||
return new ResponseEntity<>(Result.error("Github Copilot APIKey is wrong"), HttpStatus.UNAUTHORIZED);
|
||||
}
|
||||
@@ -891,7 +891,7 @@ public class chatController {
|
||||
if (resp.code() == 429) {
|
||||
return new ResponseEntity<>(Result.error("rate limit exceeded"), HttpStatus.TOO_MANY_REQUESTS);
|
||||
} else {
|
||||
String token = getCoCoToken(apiKey);
|
||||
String token = getSelfToken(apiKey);
|
||||
if (token == null) {
|
||||
return new ResponseEntity<>(Result.error("自定义 APIKey is wrong"), HttpStatus.UNAUTHORIZED);
|
||||
}
|
||||
|
Binary file not shown.
Reference in New Issue
Block a user