We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d234490 commit 72ba22dCopy full SHA for 72ba22d
1 file changed
chisel-core/src/ops/filesystem.rs
@@ -126,7 +126,7 @@ mod native {
126
reason: e.to_string(),
127
})?;
128
129
- let existing = if patch.original().map_or(false, |s| s == "/dev/null") {
+ let existing = if patch.original() == Some("/dev/null") {
130
String::new()
131
} else {
132
dir.read_to_string(&rel).map_err(|e| match e.kind() {
@@ -273,7 +273,7 @@ mod wasm_fallback {
273
274
275
276
- let new_content = if patch.original().map_or(false, |s| s == "/dev/null") {
+ let new_content = if patch.original() == Some("/dev/null") {
277
apply("", &patch).map_err(|e| CoreError::PatchFailed {
278
reason: format!("apply failed: {e:?}"),
279
})?
0 commit comments