Move cloneObject into utilities and export it.
This commit is contained in:
parent
19a1da54d1
commit
7be3a64c02
6 changed files with 12 additions and 11 deletions
|
|
@ -31,7 +31,7 @@ import * as setupCodeql from "./setup-codeql";
|
|||
import { ToolsFeature, isSupportedToolsFeature } from "./tools-features";
|
||||
import { shouldEnableIndirectTracing } from "./tracer-config";
|
||||
import * as util from "./util";
|
||||
import { BuildMode, wrapError } from "./util";
|
||||
import { BuildMode, wrapError, cloneObject } from "./util";
|
||||
|
||||
type Options = Array<string | number | boolean>;
|
||||
|
||||
|
|
@ -1344,10 +1344,6 @@ async function generateCodeScanningConfig(
|
|||
return codeScanningConfigFile;
|
||||
}
|
||||
|
||||
function cloneObject<T>(obj: T): T {
|
||||
return JSON.parse(JSON.stringify(obj)) as T;
|
||||
}
|
||||
|
||||
// This constant sets the size of each TRAP cache in megabytes.
|
||||
const TRAP_CACHE_SIZE_MB = 1024;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue