Added IAB fail-save

This commit is contained in:
M66B 2015-11-07 13:21:11 +01:00
parent 0247b2c41e
commit 468ac32e12
1 changed files with 6 additions and 0 deletions

View File

@ -320,6 +320,12 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences
} else {
int response = (data == null ? -1 : data.getIntExtra("RESPONSE_CODE", -1));
Log.i(TAG, "IAB response=" + getIABResult(response));
// Fail-safe
Intent donate = new Intent(Intent.ACTION_VIEW);
donate.setData(Uri.parse("http://www.netguard.me/"));
if (donate.resolveActivity(getPackageManager()) != null)
startActivity(donate);
}
} else {