Skip to content

Commit fb20cb3

Browse files
Make updateGlobalState and setGlobalState private again
Stop using deprecated (private) method. Use contextProxy set/getValue methods instead. Utility functions provided for brevity.
1 parent 2fb658c commit fb20cb3

File tree

2 files changed

+80
-83
lines changed

2 files changed

+80
-83
lines changed

src/core/webview/ClineProvider.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1355,14 +1355,12 @@ export class ClineProvider extends EventEmitter<ClineProviderEvents> implements
13551355
// ContextProxy
13561356

13571357
// @deprecated - Use `ContextProxy#setValue` instead.
1358-
// not private, so it can be accessed from webviewMessageHandler
1359-
async updateGlobalState<K extends keyof GlobalState>(key: K, value: GlobalState[K]) {
1358+
private async updateGlobalState<K extends keyof GlobalState>(key: K, value: GlobalState[K]) {
13601359
await this.contextProxy.setValue(key, value)
13611360
}
13621361

13631362
// @deprecated - Use `ContextProxy#getValue` instead.
1364-
// not private, so it can be accessed from webviewMessageHandler
1365-
getGlobalState<K extends keyof GlobalState>(key: K) {
1363+
private getGlobalState<K extends keyof GlobalState>(key: K) {
13661364
return this.contextProxy.getValue(key)
13671365
}
13681366

0 commit comments

Comments
 (0)