diff --git a/atlasdb-client/src/main/java/com/palantir/atlasdb/table/description/Schema.java b/atlasdb-client/src/main/java/com/palantir/atlasdb/table/description/Schema.java index 697caafc727..67b21e76796 100644 --- a/atlasdb-client/src/main/java/com/palantir/atlasdb/table/description/Schema.java +++ b/atlasdb-client/src/main/java/com/palantir/atlasdb/table/description/Schema.java @@ -292,10 +292,10 @@ public void validate() { "In index, a component derived from column must reference an existing column"); } - if (indexMetadata.getIndexType().equals(IndexType.CELL_REFERENCING)) { + if (!indexMetadata.getIndexType().equals(IndexType.ADDITIVE)) { com.palantir.logsafe.Preconditions.checkArgument( - ConflictHandler.RETRY_ON_WRITE_WRITE.equals(tableMetadata.getConflictHandler()), - "Nonadditive indexes require write-write conflicts on their tables"); + tableMetadata.getConflictHandler().checkWriteWriteConflicts(), + "Nonadditive indexes must check write-write conflicts"); } } }