Skip to content

Commit 56ac46f

Browse files
committed
Addressing PR comment: explicit logic check for assert
Signed-off-by: Ankit Kala <[email protected]>
1 parent efbd59a commit 56ac46f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/src/main/java/org/opensearch/index/shard/IndexShard.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2363,7 +2363,7 @@ public Translog.Snapshot getHistoryOperations(String reason, long startingSeqNo,
23632363
* This method should only be invoked if Segment Replication or Remote Store is not enabled.
23642364
*/
23652365
public Translog.Snapshot getHistoryOperationsFromTranslog(long startingSeqNo, long endSeqNo) throws IOException {
2366-
assert !(indexSettings.isSegRepEnabled() || indexSettings.isRemoteStoreEnabled())
2366+
assert (indexSettings.isSegRepEnabled() || indexSettings.isRemoteStoreEnabled()) == false
23672367
: "unsupported operation for segment replication enabled indices or remote store backed indices";
23682368
return getEngine().translogManager().newChangesSnapshot(startingSeqNo, endSeqNo, true);
23692369
}

0 commit comments

Comments
 (0)