Skip to content

Commit 0173fb7

Browse files
curly210102curly
and
curly
authoredMar 11, 2021
fix(prompt): modify the entry point to pass commitizen's function check (#2501)
* fix(prompt): modify the entry point to pass commitizen's function check Async Function type cannot be verified by commitizen's function check, modify to Function type. issue: #2486 (comment) * fix(prompt): modify the entry point to pass commitizen's function check Async Function type cannot be verified by commitizen's function check, modify to Function type. issue: #2486 (comment) Co-authored-by: curly <water.curly@gmail.com>
1 parent b59c733 commit 0173fb7

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed
 

‎@commitlint/prompt/src/index.ts

+5-4
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ type Commit = (input: string) => void;
99
* Entry point for commitizen
1010
* @param _ inquirer instance passed by commitizen, unused
1111
* @param commit callback to execute with complete commit message
12-
* @return generated commit message
12+
* @return {void}
1313
*/
14-
export async function prompter(_: unknown, commit: Commit): Promise<void> {
15-
const message = await input(vorpal);
16-
commit(message);
14+
export function prompter(_: unknown, commit: Commit): void {
15+
input(vorpal).then((message) => {
16+
commit(message);
17+
});
1718
}

0 commit comments

Comments
 (0)
Please sign in to comment.