diff --git a/core/src/services/onedrive/writer.rs b/core/src/services/onedrive/writer.rs index f2a35d1e57d..c6ed61f22c4 100644 --- a/core/src/services/onedrive/writer.rs +++ b/core/src/services/onedrive/writer.rs @@ -122,7 +122,7 @@ impl OneDriveWriter { } async fn create_upload_session(&self) -> Result { - let file_name_from_path = self.path.split('/').last().ok_or_else(|| { + let file_name_from_path = self.path.split('/').next_back().ok_or_else(|| { Error::new( ErrorKind::Unexpected, "connection string must have AccountName", diff --git a/core/src/services/vercel_blob/error.rs b/core/src/services/vercel_blob/error.rs index f694788867b..58f9420a1ac 100644 --- a/core/src/services/vercel_blob/error.rs +++ b/core/src/services/vercel_blob/error.rs @@ -39,7 +39,7 @@ struct VercelBlobErrorDetail { /// Parse error response into Error. pub(super) fn parse_error(resp: Response) -> Error { - let (parts, mut body) = resp.into_parts(); + let (parts, body) = resp.into_parts(); let bs = body.to_bytes(); let (kind, retryable) = match parts.status.as_u16() { diff --git a/core/src/services/webdav/error.rs b/core/src/services/webdav/error.rs index cf8c1670f5a..bc3f2f4b3bf 100644 --- a/core/src/services/webdav/error.rs +++ b/core/src/services/webdav/error.rs @@ -15,7 +15,6 @@ // specific language governing permissions and limitations // under the License. -use bytes::Buf; use http::Response; use http::StatusCode;