@@ -59,18 +59,18 @@ const issueTitleBase = 'IANA HTTP Status Code Update';
5959
6060const searchForExistingGithubIssue = async ( { lastUpdatedDate, github, context } ) => {
6161 const query = [ issueTitleBase , lastUpdatedDate , 'in:title' , `repo:${ context . payload . repository . full_name } ` , 'type:issue' ] . join ( '+' ) ;
62- const searchResult = await github . search . issuesAndPullRequests ( {
62+ const searchResponse = await github . search . issuesAndPullRequests ( {
6363 q : query ,
6464 } ) ;
65- return searchResult . data ;
65+ return searchResponse . data ;
6666} ;
6767
6868const createNewGithubIssue = async ( { httpStatusCodes, diffWithLastUsedVersion, github, context, dryRun } ) => {
6969
7070 const newIssue = {
7171 owner : context . repo . owner ,
7272 repo : context . repo . repo ,
73- title : `${ issueTitleBase } ${ httpStatusCodes . lastUpdatedDate } ` ,
73+ title : `${ issueTitleBase } ${ httpStatusCodes . lastUpdated } ` ,
7474 body : `The HTTP status codes list has been updated on ${ httpStatusCodes . lastUpdated } . ` + '\n' +
7575 'See https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml' + '\n\n' +
7676 '## Diff ##' + '\n' +
@@ -84,7 +84,8 @@ const createNewGithubIssue = async ( { httpStatusCodes, diffWithLastUsedVersion,
8484 return { number : 0 , html_url : context . payload . repository . issues_url } ;
8585 }
8686
87- return github . issues . create ( newIssue ) ;
87+ const issueResponse = await github . issues . create ( newIssue ) ;
88+ return issueResponse . data ;
8889} ;
8990
9091const getDiffWithLastUsedVersion = async ( httpStatusCodeList ) => {
0 commit comments