From 501f7ca3956e67706086e3fd5864a96cb4a618f2 Mon Sep 17 00:00:00 2001 From: Rostyslav Lesovyi Date: Tue, 18 Dec 2018 16:31:53 +0200 Subject: [PATCH] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 755a0e6..051d86b 100644 --- a/README.md +++ b/README.md @@ -112,14 +112,14 @@ Returned value will be injected as-is to final SQL statement when copying/updati Custom code can also be invoked before and after each migration: ```kotlin -@BeforeMigrationRule(version1 = 1, version2 = 2) -fun migrate_1_2_before(db: SupportSQLiteDatabase) { +@OnMigrationStartRule(version1 = 1, version2 = 2) +fun migrate_1_2_before(db: SupportSQLiteDatabase, version1: Int, version2: Int) { val cursor = db.query("pragma table_info(Object1Dbo)") assert(cursor.count == 1) } -@AfterMigrationRule(version1 = 1, version2 = 2) -fun migrate_1_2_after(db: SupportSQLiteDatabase) { +@OnMigrationEndRule(version1 = 1, version2 = 2) +fun migrate_1_2_after(db: SupportSQLiteDatabase, version1: Int, version2: Int) { val cursor = db.query("pragma table_info(Object1Dbo)") assert(cursor.count == 3) }