Skip to content

Commit

Permalink
Update pg_replicate/src/clients/delta.rs
Browse files Browse the repository at this point in the history
Co-authored-by: Raminder Singh <[email protected]>
  • Loading branch information
abduldjafar and imor authored Dec 17, 2024
1 parent 703254d commit 8556582
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions pg_replicate/src/clients/delta.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,10 @@ impl DeltaClient {
}
}

/// strips file:/// prefix from the uri
async fn strip_file_prefix(uri: &str) -> Result<&str, DeltaTableError> {
/// strips file:// prefix from the uri
fn strip_file_prefix(uri: &str) -> &str {
if let Some(path) = uri.strip_prefix("file://") {
Ok(path)
} else if let Some(path) = uri.strip_prefix("s3://") {
let _ = path;
Ok(uri)
path
} else {
panic!("strip_file_prefix called on a non-file uri")
}
Expand Down

0 comments on commit 8556582

Please sign in to comment.