nbdevos25 commented on code in PR #13253:
URL: https://github.com/apache/iceberg/pull/13253#discussion_r2534916284


##########
core/src/main/java/org/apache/iceberg/metrics/InMemoryMetricsReporter.java:
##########
@@ -35,4 +36,13 @@ public ScanReport scanReport() {
         "Metrics report is not a scan report");
     return (ScanReport) metricsReport;
   }
+
+  @Nullable
+  public CommitReport commitReport() {
+    if (metricsReport instanceof CommitReport) {
+      return (CommitReport) metricsReport;
+    } else {
+      return null;
+    }
+  }
 }

Review Comment:
   ```
   if (!metricsReport instanceof CommitReport) {
        return null
    }
    return (CommitReport) metricsReport;
   ```
   looks less verbose to me



-- 
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: [email protected]

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