Fix indentation.

This commit is contained in:
akwizgran
2018-01-16 12:54:16 +00:00
parent 2f584501fe
commit 11e2d4ecfb

View File

@@ -2049,7 +2049,7 @@ abstract class JdbcDatabase implements Database<Connection> {
int[] batchAffected = ps.executeBatch(); int[] batchAffected = ps.executeBatch();
if (batchAffected.length != requested.size()) if (batchAffected.length != requested.size())
throw new DbStateException(); throw new DbStateException();
for (int rows: batchAffected) { for (int rows : batchAffected) {
if (rows < 0) throw new DbStateException(); if (rows < 0) throw new DbStateException();
if (rows > 1) throw new DbStateException(); if (rows > 1) throw new DbStateException();
} }
@@ -2074,9 +2074,9 @@ abstract class JdbcDatabase implements Database<Connection> {
ps = txn.prepareStatement(sql); ps = txn.prepareStatement(sql);
ps.setBytes(1, g.getBytes()); ps.setBytes(1, g.getBytes());
for (Entry<String, byte[]> e : added.entrySet()) { for (Entry<String, byte[]> e : added.entrySet()) {
ps.setString(2, e.getKey()); ps.setString(2, e.getKey());
ps.setBytes(3, e.getValue()); ps.setBytes(3, e.getValue());
ps.addBatch(); ps.addBatch();
} }
int[] batchAffected = ps.executeBatch(); int[] batchAffected = ps.executeBatch();
if (batchAffected.length != added.size()) if (batchAffected.length != added.size())
@@ -2548,7 +2548,8 @@ abstract class JdbcDatabase implements Database<Connection> {
} }
@Override @Override
public void setMessageShared(Connection txn, MessageId m) throws DbException { public void setMessageShared(Connection txn, MessageId m)
throws DbException {
PreparedStatement ps = null; PreparedStatement ps = null;
try { try {
String sql = "UPDATE messages SET shared = TRUE" String sql = "UPDATE messages SET shared = TRUE"