fix bug in issueBranchRef

develop
Niclas Thobaben 2022-08-13 18:21:27 +02:00
parent 842516db17
commit 77fb599cc5
1 changed files with 5 additions and 1 deletions

View File

@ -14,7 +14,11 @@ module.exports = {
log(`Try referencing ref ${ref} to issue`)
const regex = /refs\/heads\/(feature|bugfix)\/ISS-(\d+)-/
const issueId = regex.exec(ref)[2]
const match = regex.exec(ref)
if(!match) {
return
}
const issueId = match[2]
const path = `/repos/${repository.full_name}/issues/${issueId}`