summaryrefslogtreecommitdiff
path: root/ext/node/errors.rs
diff options
context:
space:
mode:
Diffstat (limited to 'ext/node/errors.rs')
-rw-r--r--ext/node/errors.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/ext/node/errors.rs b/ext/node/errors.rs
index e0f02725f..e72cb8557 100644
--- a/ext/node/errors.rs
+++ b/ext/node/errors.rs
@@ -53,8 +53,8 @@ pub fn err_module_not_found(path: &str, base: &str, typ: &str) -> AnyError {
}
pub fn err_invalid_package_target(
- pkg_path: String,
- key: String,
+ pkg_path: &str,
+ key: &str,
target: String,
is_import: bool,
maybe_referrer: Option<String>,
@@ -95,7 +95,7 @@ pub fn err_invalid_package_target(
pub fn err_package_path_not_exported(
mut pkg_path: String,
- subpath: String,
+ subpath: &str,
maybe_referrer: Option<String>,
mode: NodeResolutionMode,
) -> AnyError {
@@ -178,7 +178,7 @@ mod test {
assert_eq!(
err_package_path_not_exported(
"test_path".to_string(),
- "./jsx-runtime".to_string(),
+ "./jsx-runtime",
None,
NodeResolutionMode::Types,
)
@@ -188,7 +188,7 @@ mod test {
assert_eq!(
err_package_path_not_exported(
"test_path".to_string(),
- ".".to_string(),
+ ".",
None,
NodeResolutionMode::Types,
)