Revert SQLiteAPIImpl changes

This commit is contained in:
Alexey Kulish 2016-09-15 16:54:56 +03:00
parent 258ab77464
commit 5e94c5ddd0

View file

@ -14,9 +14,8 @@ public class SQLiteAPIImpl implements SQLiteAPI {
@Override
public SQLiteConnection getOrCreateDatabase(String name, boolean readOnly) {
android.database.sqlite.SQLiteDatabase db = SQLiteDatabase.openDatabase(app.getDatabasePath(name).getAbsolutePath(), null,
(readOnly? SQLiteDatabase.OPEN_READONLY : (SQLiteDatabase.OPEN_READWRITE | SQLiteDatabase.ENABLE_WRITE_AHEAD_LOGGING))
| SQLiteDatabase.CREATE_IF_NECESSARY);
android.database.sqlite.SQLiteDatabase db = app.openOrCreateDatabase(name,
readOnly ? SQLiteDatabase.OPEN_READONLY : (SQLiteDatabase.OPEN_READWRITE | SQLiteDatabase.ENABLE_WRITE_AHEAD_LOGGING), null);
if(db == null) {
return null;
}