Skip to content

Commit 372c920

Browse files
committed
Apply clippy suggestions
1 parent e7cb49a commit 372c920

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

datafusion/catalog/src/async.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ struct ResolvedSchemaProvider {
3737
#[async_trait]
3838
impl SchemaProvider for ResolvedSchemaProvider {
3939
fn owner_name(&self) -> Option<&str> {
40-
self.owner_name.as_ref().map(|o| o.as_str())
40+
self.owner_name.as_deref()
4141
}
4242

4343
fn as_any(&self) -> &dyn std::any::Any {
@@ -372,8 +372,8 @@ pub trait AsyncCatalogProviderList: Send + Sync {
372372
catalog
373373
} else {
374374
let resolved_catalog = self.catalog(catalog_name).await?;
375-
let resolved_catalog = resolved_catalog
376-
.map(|async_cat| ResolvedCatalogProviderBuilder::new(async_cat));
375+
let resolved_catalog =
376+
resolved_catalog.map(ResolvedCatalogProviderBuilder::new);
377377
cached_catalogs.insert(catalog_name.to_string(), resolved_catalog);
378378
cached_catalogs.get_mut(catalog_name).unwrap()
379379
};

0 commit comments

Comments
 (0)