We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0e2a731 commit b9cec00Copy full SHA for b9cec00
ext/node/ops/require.rs
@@ -131,9 +131,6 @@ where
131
normalize_path(current_dir.join(from))
132
};
133
134
- let from = ensure_read_permission::<P>(state, &from)
135
- .map_err(RequireError::Permission)?;
136
-
137
if cfg!(windows) {
138
// return root node_modules when path is 'D:\\'.
139
let from_str = from.to_str().unwrap();
@@ -154,7 +151,7 @@ where
154
151
}
155
152
156
153
let mut paths = Vec::with_capacity(from.components().count());
157
- let mut current_path = from.as_ref();
+ let mut current_path = from.as_path();
158
let mut maybe_parent = Some(current_path);
159
while let Some(parent) = maybe_parent {
160
if !parent.ends_with("node_modules") {
0 commit comments