Skip to content

Commit

Permalink
Explicitly import performance for Node 12 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
Henry Mercer committed Aug 19, 2022
1 parent fbab93d commit b7435e9
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 6 deletions.
6 changes: 4 additions & 2 deletions lib/analyze-action.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/analyze-action.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions lib/config-utils.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/config-utils.js.map

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions src/analyze-action.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// We need to import `performance` on Node 12
import { performance } from "perf_hooks";

import * as core from "@actions/core";

import * as actionsUtil from "./actions-util";
Expand Down
2 changes: 2 additions & 0 deletions src/config-utils.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import * as fs from "fs";
import * as path from "path";
// We need to import `performance` on Node 12
import { performance } from "perf_hooks";

import * as yaml from "js-yaml";
import * as semver from "semver";
Expand Down

0 comments on commit b7435e9

Please sign in to comment.