Skip to content

Commit

Permalink
Fixed IllegalStateException thrown on ShareDataActivity
Browse files Browse the repository at this point in the history
  • Loading branch information
choiman1559 committed Apr 8, 2023
1 parent 50e5f23 commit 4329373
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ android {
applicationId "com.noti.main"
minSdkVersion 21
targetSdkVersion 33
versionCode 1011903
versionName "1.19.3"
versionCode 1011904
versionName "1.19.4"
multiDexEnabled true
ndk.abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,8 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
returnCursor2.close();

try {
BillingHelper billingHelper = BillingHelper.getInstance();
BillingHelper billingHelper = BillingHelper.getInstance(false);
if(billingHelper == null) billingHelper = BillingHelper.initialize(this);
boolean isSubscribed = billingHelper.isSubscribedOrDebugBuild();

if (size > (isSubscribed ? 2147483648L : 104857600)) {
Expand All @@ -139,6 +140,7 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
} catch (IllegalStateException e) {
BillingHelper.showSubscribeInfoDialog(ShareDataActivity.this, "Error: Can't get purchase information! Please contact developer.", false, (dialog12, which) -> finish());
isNeedToFinishActivityNow = false;
e.printStackTrace();
}

ok.setOnClickListener(v -> {
Expand Down

0 comments on commit 4329373

Please sign in to comment.