Skip to content

Commit 72bad41

Browse files
committed
fix: null报错
1 parent 70b6863 commit 72bad41

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/getCommits.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ function gitLogLoop(tagCommitObjList) {
3737
git.raw(['log', logSelection, PrettyFormats.arg], (loopErr, loopResult) => {
3838
if (loopErr) throw loopErr;
3939

40+
if (!loopResult) {
41+
loopResolve();
42+
return;
43+
}
44+
4045
const commits = PrettyFormats.parse(loopResult);
4146
let mergeCommits = tagCommitObj.commits.concat(commits);
4247

0 commit comments

Comments
 (0)