File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,5 @@ import {getQuestionSearchJson} from "#resources/headers/questionSearchJson.js";
3
3
4
4
export async function getQuestionByKeyword ( keyword ) {
5
5
const questionData = await graphql ( getQuestionSearchJson ( keyword . toString ( ) ) )
6
- console . log ( questionData )
7
6
return questionData ?. data ?. problemsetQuestionList ?. questions
8
7
}
Original file line number Diff line number Diff line change @@ -11,13 +11,14 @@ export async function easyFinderView() {
11
11
const { mode } = await inquirer . prompt ( modeQuestion , null )
12
12
const questionKeyword = [ {
13
13
type : 'input' ,
14
- name : 'identity ' ,
14
+ name : 'keyword ' ,
15
15
message : '请输入关键词:' ,
16
16
} ]
17
17
18
18
switch ( mode ) {
19
19
case '关键词搜索' :
20
- const data = await getQuestionByKeyword ( await inquirer . prompt ( questionKeyword , null ) )
20
+ const { keyword } = await inquirer . prompt ( questionKeyword , null )
21
+ const data = await getQuestionByKeyword ( keyword )
21
22
const questionList = [ {
22
23
type : 'list' ,
23
24
name : 'chooseQuestion' ,
You can’t perform that action at this time.
0 commit comments