We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4ef6dd7 commit 3c4c4a8Copy full SHA for 3c4c4a8
colorist/step_05/lib/services/gemini_chat_service.dart
@@ -29,9 +29,12 @@ class GeminiChatService {
29
final llmMessage = chatStateNotifier.createLlmMessage();
30
try {
31
final response = await chatSession.sendMessage(Content.text(message));
32
- final responseText = response.text?.trim() ?? 'No text response received';
33
- logStateNotifier.logLlmText(responseText);
34
- chatStateNotifier.appendToMessage(llmMessage.id, responseText);
+
+ final responseText = response.text;
+ if (responseText != null) {
35
+ logStateNotifier.logLlmText(responseText);
36
+ chatStateNotifier.appendToMessage(llmMessage.id, responseText);
37
+ }
38
39
if (response.functionCalls.isNotEmpty) {
40
final geminiTools = ref.read(geminiToolsProvider);
0 commit comments