Skip to content

Commit

Permalink
Fixing lint and prettier errors
Browse files Browse the repository at this point in the history
Signed-off-by: Vacha Shah <vachshah@amazon.com>
  • Loading branch information
VachaShah committed Jun 13, 2023
1 parent dc45320 commit ec2ff51
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
13 changes: 9 additions & 4 deletions src/backport.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,14 @@ const backportOnce = async ({
try {
await git("cherry-pick", "-x", "-n", commitSha);
} catch (error: unknown) {
logError(
"Possibly a conflict error. Trying to skip possible conflict files. ",
);
if (error instanceof Error) {
logError(
"Possibly a conflict error. Trying to skip possible conflict files. ",
);
console.log(error.message);
} else {
console.log("Unexpected error", error);
}
}

/* eslint-disable no-await-in-loop */
Expand Down Expand Up @@ -333,7 +338,7 @@ const backport = async ({
commitSha: mergeCommitSha,
errorMessage: error.message,
head,
repo
repo,
}),
issue_number: number,
owner,
Expand Down
1 change: 0 additions & 1 deletion xo.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ module.exports = {
"newlines-between": "never",
},
],
"no-console": "error",
"object-shorthand": [
"error",
"always",
Expand Down

0 comments on commit ec2ff51

Please sign in to comment.