Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
  • Loading branch information
tot-ra committed Sep 12, 2023
1 parent d77b22b commit 55584e7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 20 deletions.
22 changes: 4 additions & 18 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14642,18 +14642,6 @@ module.exports = JSON.parse('[[[0,44],"disallowed_STD3_valid"],[[45,46],"valid"]
/******/ __nccwpck_require__.m = __webpack_modules__;
/******/
/************************************************************************/
/******/ /* webpack/runtime/compat get default export */
/******/ (() => {
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __nccwpck_require__.n = (module) => {
/******/ var getter = module && module.__esModule ?
/******/ () => (module['default']) :
/******/ () => (module);
/******/ __nccwpck_require__.d(getter, { a: getter });
/******/ return getter;
/******/ };
/******/ })();
/******/
/******/ /* webpack/runtime/define property getters */
/******/ (() => {
/******/ // define getter functions for harmony exports
Expand Down Expand Up @@ -14760,10 +14748,8 @@ __nccwpck_require__.r(__webpack_exports__);

// EXTERNAL MODULE: ./node_modules/@actions/core/lib/core.js
var core = __nccwpck_require__(7820);
var core_default = /*#__PURE__*/__nccwpck_require__.n(core);
// EXTERNAL MODULE: ./node_modules/@actions/github/lib/github.js
var github = __nccwpck_require__(3737);
var github_default = /*#__PURE__*/__nccwpck_require__.n(github);
;// CONCATENATED MODULE: external "node:http"
const external_node_http_namespaceObject = require("node:http");
;// CONCATENATED MODULE: external "node:https"
Expand Down Expand Up @@ -16916,7 +16902,7 @@ function fixResponseChunkedTransferBadEnding(request, errorCallback) {

async function reviewPR() {
try {
const octokit = github_default().getOctokit(process.env.GITHUB_TOKEN)
const octokit = github.getOctokit(process.env.GITHUB_TOKEN)

const ctx = {
owner: process.env.PR_OWNER,
Expand All @@ -16926,7 +16912,7 @@ async function reviewPR() {
console.log("Using this data for PR check", ctx)

if(!process.env.PR_NUMBER){
core_default().setFailed("No PR number detected. Wrong event type?");
core.setFailed("No PR number detected. Wrong event type?");
return
}

Expand All @@ -16942,7 +16928,7 @@ async function reviewPR() {
} catch (error) {
console.error("Failed at getting PR data")
console.error(error.message)
core_default().setFailed(error.message);
core.setFailed(error.message);
return
}

Expand Down Expand Up @@ -17004,7 +16990,7 @@ async function reviewPR() {
})

} catch (error) {
core_default().setFailed(error.message);
core.setFailed(error.message);
}
}

Expand Down
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import core from '@actions/core';
import github from '@actions/github';
import * as core from '@actions/core'
import * as github from '@actions/github';
import fetch from 'node-fetch';

async function reviewPR() {
Expand Down

0 comments on commit 55584e7

Please sign in to comment.