From 0e2f0621486239739ebfce4db4d629e6d2df2148 Mon Sep 17 00:00:00 2001 From: Mauricio Colli Date: Sun, 28 Apr 2019 17:43:52 -0300 Subject: [PATCH] Disable database destructive migration fallback This really shouldn't be enabled, as this database is not just a temp one. Making the mistake of shipping the app without a proper migration would cause a big problem. Really hard to happen but an error is far better than data loss. --- app/src/main/java/org/schabi/newpipe/NewPipeDatabase.java | 1 - 1 file changed, 1 deletion(-) diff --git a/app/src/main/java/org/schabi/newpipe/NewPipeDatabase.java b/app/src/main/java/org/schabi/newpipe/NewPipeDatabase.java index 605bed09c..13c643edb 100644 --- a/app/src/main/java/org/schabi/newpipe/NewPipeDatabase.java +++ b/app/src/main/java/org/schabi/newpipe/NewPipeDatabase.java @@ -23,7 +23,6 @@ public final class NewPipeDatabase { return Room .databaseBuilder(context.getApplicationContext(), AppDatabase.class, DATABASE_NAME) .addMigrations(MIGRATION_11_12) - .fallbackToDestructiveMigration() .build(); }