Skip to content

Commit edada25

Browse files
committed
fix: Expose version and if_match fields in DeleteOptions
Signed-off-by: Shashank Singh <[email protected]>
1 parent 996a20c commit edada25

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

bindings/nodejs/src/options.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,8 @@ impl From<WriteOptions> for opendal::options::WriteOptions {
508508
#[derive(Default)]
509509
pub struct DeleteOptions {
510510
pub version: Option<String>,
511+
/// Set `if_match` for this operation.
512+
pub if_match: Option<String>,
511513
/// Whether to delete recursively.
512514
pub recursive: Option<bool>,
513515
}
@@ -516,6 +518,7 @@ impl From<DeleteOptions> for opendal::options::DeleteOptions {
516518
fn from(value: DeleteOptions) -> Self {
517519
Self {
518520
version: value.version,
521+
if_match: value.if_match,
519522
recursive: value.recursive.unwrap_or_default(),
520523
}
521524
}

core/services/s3/src/backend.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -930,7 +930,8 @@ impl Builder for S3Builder {
930930
copy_with_if_not_exists: true,
931931
copy_with_if_match: true,
932932

933-
rename: true,
933+
list: true,
934+
rename: false,
934935
list_with_limit: true,
935936
list_with_start_after: true,
936937
list_with_recursive: true,

0 commit comments

Comments
 (0)