File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11// SPDX-FileCopyrightText: 2026 LibreCode coop and contributors
22// SPDX-License-Identifier: AGPL-3.0-or-later
33
4+ import { Buffer } from 'node:buffer'
45import { readdir , readFile } from 'node:fs/promises'
56import path from 'node:path'
67import process from 'node:process'
@@ -97,7 +98,7 @@ export async function validatePdfjsDist({ rootDir } = {}) {
9798
9899async function main ( ) {
99100 const result = await validatePdfjsDist ( )
100- console . log (
101+ globalThis . console . log (
101102 `Validated PDF.js dist chunks: runtime ${ result . runtimeChunk } and worker ${ result . workerChunk } both use ${ result . runtimeVersion } .`
102103 )
103104}
@@ -106,7 +107,7 @@ const invokedPath = process.argv[1] ? pathToFileURL(path.resolve(process.argv[1]
106107
107108if ( invokedPath === import . meta. url ) {
108109 main ( ) . catch ( ( error ) => {
109- console . error ( error instanceof Error ? error . message : error )
110+ globalThis . console . error ( error instanceof Error ? error . message : error )
110111 process . exitCode = 1
111112 } )
112113}
You can’t perform that action at this time.
0 commit comments