Skip to content

Commit 5a33e96

Browse files
shangxinliwgtmac
andauthored
Update src/iceberg/table_requirement.cc
Co-authored-by: Gang Wu <[email protected]>
1 parent 35e88f7 commit 5a33e96

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/iceberg/table_requirement.cc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -127,11 +127,7 @@ Status AssertCurrentSchemaID::Validate(const TableMetadata* base) const {
127127
Status AssertLastAssignedPartitionId::Validate(const TableMetadata* base) const {
128128
// Validate that the last assigned partition ID matches the expected value
129129

130-
if (base == nullptr) {
131-
return CommitFailed("Requirement failed: current table metadata is missing");
132-
}
133-
134-
if (base->last_partition_id != last_assigned_partition_id_) {
130+
if (base && base->last_partition_id != last_assigned_partition_id_) {
135131
return CommitFailed(
136132
"Requirement failed: last assigned partition ID does not match (expected={}, "
137133
"actual={})",

0 commit comments

Comments
 (0)