diff --git a/.github/workflows/issues-scan.yml b/.github/workflows/issues-scan.yml index 690e6172..912fc4b7 100755 --- a/.github/workflows/issues-scan.yml +++ b/.github/workflows/issues-scan.yml @@ -305,19 +305,9 @@ jobs: console.log(` PR Context ............ ${ context }`) console.log(`-----------------------------------------------------------------------------------------------`) - const targetOwner = context.repo.owner; - const targetRepo = context.repo.repo; - - // Fetch labels from the source repository - const response = await github.rest.issues.listLabelsForRepo({ - owner: targetOwner, - repo: targetRepo, - }); - console.log("Labels fetched: ", response.data); - const fs = require( 'fs' ); const escape_html = ( unsafe ) => unsafe.replace( /&/g, '&' ).replace( //g, '>' ).replace( /"/g, '"' ).replace( /'/g, ''' ); - const labels = response.data; + const labels = context.payload.pull_request.labels; console.log(`-----------------------------------------------------------------------------------------------`) console.log(` PR Labels ............ ${ labels }`)