mirror of
https://github.com/hmalik144/Weather-apps.git
synced 2026-10-30 07:36:21 +00:00
- fix db bug (#28)
This commit is contained in:
1 parent
d08d8f78de
commit
9df83eb083
1 file changed
+3
-1
@@ -5,11 +5,12 @@ import androidx.room.Database
|
||||
import androidx.room.Room
|
||||
import androidx.room.RoomDatabase
|
||||
import androidx.room.TypeConverters
|
||||
import androidx.room.migration.Migration
|
||||
import com.appttude.h_mal.atlas_weather.data.room.entity.EntityItem
|
||||
|
||||
@Database(
|
||||
entities = [EntityItem::class],
|
||||
version = 1,
|
||||
version = 2,
|
||||
exportSchema = false
|
||||
)
|
||||
@TypeConverters(Converter::class)
|
||||
@@ -36,6 +37,7 @@ abstract class AppDatabase : RoomDatabase() {
|
||||
AppDatabase::class.java,
|
||||
"MyDatabase.db"
|
||||
).addTypeConverter(Converter(context))
|
||||
.addMigrations(Migration(1,2) { })
|
||||
.build()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user