Skip to content

Commit bbc460e

Browse files
authored
Support Path for resolve_path (denoland#851)
Simple change that seems to be the last link in allowing module loads using Path instead of str
1 parent 172c71a commit bbc460e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/module_specifier.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ pub fn resolve_url_or_path(
124124
/// ModuleSpecifier. A relative path is considered relative to the passed
125125
/// `current_dir`.
126126
pub fn resolve_path(
127-
path_str: &str,
127+
path_str: impl AsRef<Path>,
128128
current_dir: &Path,
129129
) -> Result<ModuleSpecifier, ModuleResolutionError> {
130130
let path = current_dir.join(path_str);

0 commit comments

Comments
 (0)