File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -109,15 +109,15 @@ function defaultGetResource(pathCx : PathContext, options : Options) : Resource
109
109
* ```
110
110
*
111
111
*/
112
- export async function loadModule ( path : string , options_ : Options = throwNotDefined ( 'options' ) ) : Promise < ModuleExport > {
112
+ export async function loadModule ( path : string , options : Options = throwNotDefined ( 'options' ) ) : Promise < ModuleExport > {
113
113
114
114
const {
115
115
moduleCache = Object . create ( null ) ,
116
116
getFile = throwNotDefined ( 'options.getFile()' ) ,
117
117
addStyle = throwNotDefined ( 'options.addStyle()' ) ,
118
118
pathHandlers = defaultPathHandlers ,
119
119
getResource = defaultGetResource ,
120
- } = options_ ;
120
+ } = options ;
121
121
122
122
123
123
// TBD: remove this in v1.0
@@ -127,15 +127,15 @@ export async function loadModule(path : string, options_ : Options = throwNotDef
127
127
return typeof res === 'object' ? res : { content : res , extname : pathHandlers . extname ( path ) } ;
128
128
}
129
129
130
- const options = {
130
+ const normalizedOptions = {
131
131
moduleCache,
132
132
pathHandlers,
133
133
getResource,
134
- ...options_ ,
134
+ ...options ,
135
135
getFile : normalizedGetFile ,
136
136
} ;
137
137
138
- return await loadModuleInternal ( { refPath : '/' , relPath : path } , options ) ;
138
+ return await loadModuleInternal ( { refPath : '/' , relPath : path } , normalizedOptions ) ;
139
139
}
140
140
141
141
/**
You can’t perform that action at this time.
0 commit comments