File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ export class TodoListContextProvider implements ITodoListContextProvider {
38
38
. map ( part => part . value )
39
39
. join ( '\n' ) ;
40
40
41
- if ( ! todoList . trim ( ) ) {
41
+ if ( ! todoList . trim ( ) || todoList === 'No todo list found.' ) {
42
42
return undefined ;
43
43
}
44
44
Original file line number Diff line number Diff line change 6
6
import { BasePromptElementProps , PromptElement } from '@vscode/prompt-tsx' ;
7
7
import { ITodoListContextProvider } from '../../prompt/node/todoListContextProvider' ;
8
8
import { Tag } from '../../prompts/node/base/tag' ;
9
- import { ToolName } from '../common/toolNames' ;
10
9
11
10
export interface TodoListContextPromptProps extends BasePromptElementProps {
12
11
sessionId ?: string ;
@@ -29,9 +28,12 @@ export class TodoListContextPrompt extends PromptElement<TodoListContextPromptPr
29
28
return null ;
30
29
}
31
30
const todoContext = await this . todoListContextProvider . getCurrentTodoContext ( sessionId ) ;
31
+ if ( ! todoContext ) {
32
+ return null ;
33
+ }
32
34
return (
33
35
< Tag name = "todoList" >
34
- { todoContext || < > Empty todo list. Call ` { ToolName . CoreManageTodoList } ` to set todos as needed. </ > }
36
+ { todoContext }
35
37
</ Tag >
36
38
) ;
37
39
}
You can’t perform that action at this time.
0 commit comments