diff --git a/library/build.gradle b/library/build.gradle
index 6bb04c8..d7bf697 100644
--- a/library/build.gradle
+++ b/library/build.gradle
@@ -9,7 +9,7 @@ android {
         compileSdk = 33
         buildToolsVersion = '30.0.3'
 
-        minSdkVersion 19
+        minSdkVersion 21
         targetSdkVersion 33
         consumerProguardFiles 'progress-proguard.txt'
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -33,7 +33,7 @@ dependencies {
     androidTestImplementation 'androidx.test:rules:1.4.0'
     androidTestImplementation 'androidx.test:runner:1.4.0'
     implementation 'androidx.annotation:annotation:1.3.0'
-    implementation 'com.android.billingclient:billing:6.1.0'
+    implementation 'com.android.billingclient:billing:7.0.0'
 }
 
 task androidJavadocs(type: Javadoc) {
diff --git a/library/src/main/java/com/anjlab/android/iab/v3/BillingProcessor.java b/library/src/main/java/com/anjlab/android/iab/v3/BillingProcessor.java
index 548ec51..c8da354 100644
--- a/library/src/main/java/com/anjlab/android/iab/v3/BillingProcessor.java
+++ b/library/src/main/java/com/anjlab/android/iab/v3/BillingProcessor.java
@@ -694,7 +694,8 @@ public void run()
 						billingFlowParamsBuilder.setSubscriptionUpdateParams(
 								BillingFlowParams.SubscriptionUpdateParams
 										.newBuilder()
-										.setOldSkuPurchaseToken(oldToken)
+
+										.setOldPurchaseToken(oldToken)
 										.build());
 					}
 				}
diff --git a/sample/build.gradle b/sample/build.gradle
index a19cdda..e9b6838 100644
--- a/sample/build.gradle
+++ b/sample/build.gradle
@@ -14,7 +14,7 @@ android {
     defaultConfig {
         versionCode 5
         versionName '5.0'
-        minSdkVersion 19
+        minSdkVersion 21
         targetSdkVersion 33
         compileSdk = 33
         buildToolsVersion = '30.0.3'