Skip to content

Commit 724e7dc

Browse files
committed
修复API 34编译问题
1 parent f7fb577 commit 724e7dc

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

TMessagesProj/src/main/java/org/telegram/messenger/SendMessagesHelper.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -6945,8 +6945,9 @@ private void sendMessageGoogle(String aiModelReal, final String prompt, Double t
69456945
List<ChatGSafetySetting> safetySettings = new ArrayList<>();
69466946

69476947
for(ChatGSafetyCategory category : ChatGSafetyCategory.values()) {
6948+
if (category == null) continue;
69486949
ChatGSafetySetting safetySetting = ChatGSafetySetting.builder()
6949-
.category(category.value())
6950+
.category(category.getValue())
69506951
.threshold(ChatGSafetyThreshold.BLOCK_NONE.value())
69516952
.build();
69526953

openai_api/src/main/java/com/theokanning/openai/completion/chat/ChatGSafetyCategory.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public enum ChatGSafetyCategory {
1616
this.value = value;
1717
}
1818

19-
public String value() {
19+
public String getValue() {
2020
return value;
2121
}
2222

0 commit comments

Comments
 (0)