|
|
@@ -1149,23 +1149,24 @@ ${prompt}
|
|
|
}
|
|
|
|
|
|
public async postMessageToWebview(message: ExtensionMessage) {
|
|
|
- // kilocode_change start
|
|
|
- if (message.type === "apiMessagesSaved" && message.payload) {
|
|
|
- const [taskId, filePath] = message.payload as [string, string]
|
|
|
+ // NOTE: Changing this? Update effects.ts in the cli too.
|
|
|
+ kilo_execIfExtension(() => {
|
|
|
+ if (message.type === "apiMessagesSaved" && message.payload) {
|
|
|
+ const [taskId, filePath] = message.payload as [string, string]
|
|
|
|
|
|
- SessionManager.init().handleFileUpdate(taskId, "apiConversationHistoryPath", filePath)
|
|
|
- } else if (message.type === "taskMessagesSaved" && message.payload) {
|
|
|
- const [taskId, filePath] = message.payload as [string, string]
|
|
|
+ SessionManager.init().handleFileUpdate(taskId, "apiConversationHistoryPath", filePath)
|
|
|
+ } else if (message.type === "taskMessagesSaved" && message.payload) {
|
|
|
+ const [taskId, filePath] = message.payload as [string, string]
|
|
|
|
|
|
- SessionManager.init().handleFileUpdate(taskId, "uiMessagesPath", filePath)
|
|
|
- } else if (message.type === "taskMetadataSaved" && message.payload) {
|
|
|
- const [taskId, filePath] = message.payload as [string, string]
|
|
|
+ SessionManager.init().handleFileUpdate(taskId, "uiMessagesPath", filePath)
|
|
|
+ } else if (message.type === "taskMetadataSaved" && message.payload) {
|
|
|
+ const [taskId, filePath] = message.payload as [string, string]
|
|
|
|
|
|
- SessionManager.init().handleFileUpdate(taskId, "taskMetadataPath", filePath)
|
|
|
- } else if (message.type === "currentCheckpointUpdated") {
|
|
|
- SessionManager.init().doSync()
|
|
|
- }
|
|
|
- // kilocode_change end
|
|
|
+ SessionManager.init().handleFileUpdate(taskId, "taskMetadataPath", filePath)
|
|
|
+ } else if (message.type === "currentCheckpointUpdated") {
|
|
|
+ SessionManager.init().doSync()
|
|
|
+ }
|
|
|
+ })
|
|
|
|
|
|
await this.view?.webview.postMessage(message)
|
|
|
}
|