diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 666ffba..816ff76 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -137,9 +137,10 @@ jobs: sonar.sourceEncoding=UTF-8 EOF - name: SonarScanner - if: github.event.pull_request.base.repo.owner.login == 'usdot-jpo-ode' + if: github.event_name == 'pull_request' && github.repository_owner == 'usdot-jpo-ode' uses: usdot-fhwa-stol/actions/sonar-scanner@main with: sonar-properties-path: /tmp/sonar-scanner.properties sonar-token: ${{ secrets.SONAR_TOKEN }} working-dir: $GITHUB_WORKSPACE +