Revert "Revert "Revert "App: only init the data store once per application."""

Even more reverts. :(
After additional testing (based on user reports) it seems like this may
still be causing issues. I find it weird and don't understand why, but
I'm reverting this as a precaution so people aren't affected.

Related to #97

This reverts commit da3ac48bbf.
pull/104/head
Tom Hacohen 5 years ago
parent 591a37da9b
commit 72253932d3

@ -51,7 +51,8 @@ class App : Application() {
* `@Provides @Singleton`.
*/
// override onUpgrade to handle migrating to a new version
val data = initDataStore()
val data: MyEntityDataStore
get() = initDataStore()
fun initDataStore(): MyEntityDataStore {
val source = MyDatabaseSource(this, Models.DEFAULT, 4)

Loading…
Cancel
Save