Skip to content

Commit

Permalink
fix: update
Browse files Browse the repository at this point in the history
  • Loading branch information
zmhu committed Dec 13, 2023
1 parent e609725 commit 65d2fca
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
9 changes: 6 additions & 3 deletions lib/util/input_submit_util.dart
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class InputSubmitUtil {
model: chatSessionController.currentSession.model,
msgType: 1,
synced: false,
updated: getCurrentDateTime(),
updated: getCurrentDateTime() + 1,
generating: true,
);
chatMessageController.addMessage(targetMessage);
Expand All @@ -105,6 +105,7 @@ class InputSubmitUtil {
targetMessage.generating = false;
targetMessage.closeStream();
chatMessageController.saveMessage(userMessage);
targetMessage.updated = getCurrentDateTime() + 1;
chatMessageController.saveMessage(targetMessage);
chatSessionController
.updateSessionLastEdit(chatSessionController.currentSession);
Expand Down Expand Up @@ -229,7 +230,7 @@ class InputSubmitUtil {
model: chatSessionController.currentSession.model,
msgType: 1,
synced: false,
updated: getCurrentDateTime(),
updated: getCurrentDateTime() + 1,
generating: true,
);
chatMessageController.addMessage(targetMessage);
Expand All @@ -255,6 +256,7 @@ class InputSubmitUtil {
targetMessage.generating = false;
targetMessage.closeStream();
chatMessageController.saveMessage(userMessage);
targetMessage.updated = getCurrentDateTime() + 1;
chatMessageController.saveMessage(targetMessage);
chatSessionController
.updateSessionLastEdit(chatSessionController.currentSession);
Expand Down Expand Up @@ -387,6 +389,7 @@ class InputSubmitUtil {
chatSessionController.currentSession.sid, 'assistant', '', false);
targetMessage.responseJson = jsonEncode(images.json);
targetMessage.status = 1;
targetMessage.updated = getCurrentDateTime() + 1;
chatMessageController.addMessage(targetMessage);
chatMessageController.update();
chatMessageController.saveMessage(userMessage);
Expand Down Expand Up @@ -442,7 +445,7 @@ class InputSubmitUtil {
msgType: 1,
synced: false,
generating: false,
updated: getCurrentDateTime() + 1,
updated: getCurrentDateTime() + 5,
);

chatMessageController.addMessage(targetMessage);
Expand Down
2 changes: 1 addition & 1 deletion macos/Flutter/GeneratedPluginRegistrant.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import window_manager
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin"))
IsarFlutterLibsPlugin.register(with: registry.registrar(forPlugin: "IsarFlutterLibsPlugin"))
FLTPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FLTPackageInfoPlusPlugin"))
FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin"))
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
ScreenRetrieverPlugin.register(with: registry.registrar(forPlugin: "ScreenRetrieverPlugin"))
UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin"))
Expand Down
2 changes: 1 addition & 1 deletion macos/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 236401fc2c932af29a9fcf0e97baeeb2d750d367

COCOAPODS: 1.14.1
COCOAPODS: 1.13.0

0 comments on commit 65d2fca

Please sign in to comment.