Skip to content

Commit fa3e0c8

Browse files
aduh95RafaelGSS
authored andcommitted
esm: mark importAssertions as required
We already always specify a value, and failing to do so would likely be a bug. PR-URL: #46164 Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Michaël Zasso <[email protected]>
1 parent e1c56ec commit fa3e0c8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/internal/modules/esm/loader.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -777,14 +777,14 @@ class ESMLoader {
777777
* @param {string} originalSpecifier The specified URL path of the module to
778778
* be resolved.
779779
* @param {string} [parentURL] The URL path of the module's parent.
780-
* @param {ImportAssertions} [importAssertions] Assertions from the import
780+
* @param {ImportAssertions} importAssertions Assertions from the import
781781
* statement or expression.
782782
* @returns {{ format: string, url: URL['href'] }}
783783
*/
784784
async resolve(
785785
originalSpecifier,
786786
parentURL,
787-
importAssertions = { __proto__: null },
787+
importAssertions,
788788
) {
789789
const isMain = parentURL === undefined;
790790

0 commit comments

Comments
 (0)