use apply for preferences instead of commit

// FREEBIE
This commit is contained in:
Jake McGinty
2014-05-05 13:48:26 -05:00
committed by Moxie Marlinspike
parent d8e6a93584
commit 34e147838a
10 changed files with 60 additions and 33 deletions

View File

@@ -215,6 +215,6 @@ public class ApplicationMigrationService extends Service
}
public static void setDatabaseImported(Context context) {
context.getSharedPreferences(PREFERENCES_NAME, 0).edit().putBoolean(DATABASE_MIGRATED, true).commit();
context.getSharedPreferences(PREFERENCES_NAME, 0).edit().putBoolean(DATABASE_MIGRATED, true).apply();
}
}