Skip to content

Commit 2a9243b

Browse files
authored
Update @vercel/nft from 0.10.0 to 0.19.1 (#320)
1 parent e96ce9a commit 2a9243b

3 files changed

Lines changed: 152 additions & 47 deletions

File tree

packages/runtime/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"@types/semver": "6.0.0",
2828
"@types/yazl": "2.4.1",
2929
"@vercel/build-utils": "2.17.0",
30-
"@vercel/nft": "0.10.0",
30+
"@vercel/nft": "0.19.1",
3131
"@vercel/routing-utils": "1.10.1",
3232
"async-sema": "3.0.1",
3333
"buffer-crc32": "0.2.13",

packages/runtime/src/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1153,16 +1153,16 @@ export async function build({
11531153
debug(`node-file-trace result for pages: ${fileList}`);
11541154

11551155
const lstatSema = new Sema(25, {
1156-
capacity: fileList.length + apiFileList.length,
1156+
capacity: fileList.size + apiFileList.size,
11571157
});
11581158
const lstatResults: { [key: string]: ReturnType<typeof lstat> } = {};
11591159

11601160
const collectTracedFiles = (
11611161
reasons: NodeFileTraceReasons,
11621162
files: { [filePath: string]: FileFsRef }
11631163
) => async (file: string) => {
1164-
const reason = reasons[file];
1165-
if (reason && reason.type === 'initial') {
1164+
const reason = reasons.get(file);
1165+
if (reason && reason.type.indexOf( 'initial') !== -1) {
11661166
// Initial files are manually added to the lambda later
11671167
return;
11681168
}
@@ -1183,10 +1183,10 @@ export async function build({
11831183
};
11841184

11851185
await Promise.all(
1186-
fileList.map(collectTracedFiles(nonApiReasons, tracedFiles))
1186+
Array.from(fileList).map(collectTracedFiles(nonApiReasons, tracedFiles))
11871187
);
11881188
await Promise.all(
1189-
apiFileList.map(collectTracedFiles(apiReasons, apiTracedFiles))
1189+
Array.from(apiFileList).map(collectTracedFiles(apiReasons, apiTracedFiles))
11901190
);
11911191

11921192
if (hasLambdas) {

0 commit comments

Comments
 (0)