You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/04/13 18:19:22 UTC

[GitHub] [arrow-datafusion] alamb commented on a diff in pull request #2222: minor: Refactor to avoid repeated code in replace_qualifier

alamb commented on code in PR #2222:
URL: https://github.com/apache/arrow-datafusion/pull/2222#discussion_r849770007


##########
datafusion/common/src/dfschema.rs:
##########
@@ -324,14 +324,7 @@ impl DFSchema {
             fields: self
                 .fields
                 .into_iter()
-                .map(|f| {
-                    DFField::new(
-                        Some(qualifier),
-                        f.name(),
-                        f.data_type().to_owned(),
-                        f.is_nullable(),
-                    )
-                })
+                .map(|f| DFField::from_qualified(qualifier, f.field))

Review Comment:
   not that it matters, but this also saves a copy of field I think 👍 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org