mirror of
https://github.com/github/codeql-action.git
synced 2026-01-04 21:50:17 +08:00
Use url.pathToFileURL instead of file-url
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
import * as fs from "fs";
|
||||
import * as path from "path";
|
||||
import * as url from "url";
|
||||
import zlib from "zlib";
|
||||
|
||||
import * as core from "@actions/core";
|
||||
import { OctokitResponse } from "@octokit/types";
|
||||
import fileUrl from "file-url";
|
||||
import * as jsonschema from "jsonschema";
|
||||
|
||||
import * as actionsUtil from "./actions-util";
|
||||
@@ -728,7 +728,7 @@ export async function uploadSpecifiedFiles(
|
||||
const sarifPayload = JSON.stringify(sarif);
|
||||
logger.debug(`Compressing serialized SARIF`);
|
||||
const zippedSarif = zlib.gzipSync(sarifPayload).toString("base64");
|
||||
const checkoutURI = fileUrl(checkoutPath);
|
||||
const checkoutURI = url.pathToFileURL(checkoutPath).href;
|
||||
|
||||
const payload = buildPayload(
|
||||
await gitUtils.getCommitOid(checkoutPath),
|
||||
|
||||
Reference in New Issue
Block a user