}
public static synchronized void init(Application context) {
MLDB.context = context;
- if (dbHelper != null) throw new IllegalStateException("It appears init() was already called");
+ if (dbHelper != null)
+ throw new IllegalStateException("It appears init() was already called");
dbHelper = new MobileLedgerDatabase(context);
}
public static synchronized void done() {
class MobileLedgerDatabase extends SQLiteOpenHelper implements AutoCloseable {
private static final String DB_NAME = "MoLe.db";
- private static final int LATEST_REVISION = 20;
- private static final String CREATE_DB_SQL = "create-db.sql";
+ private static final int LATEST_REVISION = 21;
+ private static final String CREATE_DB_SQL = "create_db";
private final Application mContext;