}
final Object toReturn = super.visitPrepareCommand(ctx, command);
if (ctx.isTransactionValid()) {
final TransactionContext transactionContext = makeTransactionalEventContext();
for (int i = 0; i < writeCommands.length; i++) {
final WriteCommand writeCommand = writeCommands[i];
if (writeCommand instanceof PutKeyValueCommand) {
processPutKeyValueCommand((PutKeyValueCommand) writeCommand, ctx, stateBeforePrepare[i], transactionContext);
} else if (writeCommand instanceof PutMapCommand) {