Skip to content

Commit

Permalink
fix: use substring start and end correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
EYssel committed Oct 6, 2024
1 parent 6353e2e commit 780cbee
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion bin/lambda-sqlite-efs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ const GIT_BRANCH = process.env.GIT_BRANCH;
const getBranchprefix = (branchName: string) => {
console.log("branchName", branchName);
return branchName && branchName !== `master`
? `${branchName.replace(/\b(feat|fix|chore)\/?\b/g, "").substring(10)}-`
? `${branchName
.replace(/\b(feat|fix|chore)\/?\b/g, "")
.substring(0, 5)}-`
: "";
};

Expand Down

0 comments on commit 780cbee

Please sign in to comment.