Skip to content

Commit 3e7de5b

Browse files
committed
build: lock file maintenance
See associated pull request for more information. Closes angular#30625 as a pr takeover
1 parent 7da683d commit 3e7de5b

File tree

2 files changed

+525
-615
lines changed

2 files changed

+525
-615
lines changed

packages/angular/build/src/utils/index-file/inline-fonts.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import { HttpsProxyAgent } from 'https-proxy-agent';
1010
import { createHash } from 'node:crypto';
1111
import { readFile, rm, writeFile } from 'node:fs/promises';
1212
import * as https from 'node:https';
13+
import { Agent } from 'node:https';
1314
import { join } from 'node:path';
1415
import { NormalizedCachedOptions } from '../normalize-cache';
1516
import { htmlRewritingStream } from './html-rewriting-stream';
@@ -194,11 +195,12 @@ export class InlineFontsProcessor {
194195
} catch {}
195196
}
196197

197-
let agent: HttpsProxyAgent<string> | undefined;
198+
let agent: Agent | undefined;
198199
const httpsProxy = process.env.HTTPS_PROXY ?? process.env.https_proxy;
199200

200201
if (httpsProxy) {
201-
agent = new HttpsProxyAgent(httpsProxy);
202+
// TODO(alanagius): remove casting https://github.com/TooTallNate/proxy-agents/issues/379 is fixed.
203+
agent = new HttpsProxyAgent(httpsProxy) as Agent;
202204
}
203205

204206
const data = await new Promise<string>((resolve, reject) => {

0 commit comments

Comments
 (0)