fix: include includeCurrentTime/Cost settings in state methods

- Add includeCurrentTime and includeCurrentCost to getStateToPostToWebview()
- Add them to the destructuring in getStateToPostToWebview()
- Add them to the return object in getState()
- This ensures the settings are properly loaded from storage and displayed in UI
- Fixes persistence issue where settings would reset when reopening settings panel
This commit is contained in:
daniel-lxs 2025-10-27 16:06:43 -05:00
parent d370b8ba53
commit 5d31f8f61f
No known key found for this signature in database
GPG key ID: 21C74479048B3AA6

View file

@ -1813,6 +1813,8 @@ export class ClineProvider
includeDiagnosticMessages,
maxDiagnosticMessages,
includeTaskHistoryInEnhance,
includeCurrentTime,
includeCurrentCost,
taskSyncEnabled,
remoteControlEnabled,
openRouterImageApiKey,
@ -1961,6 +1963,8 @@ export class ClineProvider
includeDiagnosticMessages: includeDiagnosticMessages ?? true,
maxDiagnosticMessages: maxDiagnosticMessages ?? 50,
includeTaskHistoryInEnhance: includeTaskHistoryInEnhance ?? true,
includeCurrentTime: includeCurrentTime ?? true,
includeCurrentCost: includeCurrentCost ?? true,
taskSyncEnabled,
remoteControlEnabled,
openRouterImageApiKey,
@ -2173,6 +2177,8 @@ export class ClineProvider
includeDiagnosticMessages: stateValues.includeDiagnosticMessages ?? true,
maxDiagnosticMessages: stateValues.maxDiagnosticMessages ?? 50,
includeTaskHistoryInEnhance: stateValues.includeTaskHistoryInEnhance ?? true,
includeCurrentTime: stateValues.includeCurrentTime ?? true,
includeCurrentCost: stateValues.includeCurrentCost ?? true,
taskSyncEnabled,
remoteControlEnabled: (() => {
try {