RussellSpitzer commented on a change in pull request #1715:
URL: https://github.com/apache/iceberg/pull/1715#discussion_r525603746



##########
File path: spark/src/main/java/org/apache/iceberg/actions/BaseSparkAction.java
##########
@@ -86,6 +126,32 @@
     return manifestDF.union(otherMetadataFileDF).union(manifestListDF);
   }
 
+  protected static Dataset<Row> loadMetadataTable(SparkSession spark, String 
tableName, String tableLocation,
+                                                  MetadataTableType type) {
+    DataFrameReader noCatalogReader = spark.read().format("iceberg");
+    if (tableName.contains("/")) {
+      // Metadata location passed, load without a catalog
+      return noCatalogReader.load(tableName + "#" + type);
+    } else {

Review comment:
       It helps for my brain,  but I can drop the if else if you like. I tend 
to prefer nesting over implied control flow breaks but I think I'm not in the 
majority here. I'll change it since its what we did on the other pr as well




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to