fix crash by payments when run on android 5.1.1 device.

(http://stackoverflow.com/questions/24480069/google-in-app-billing-illegalargumentexception-service-intent-must-be-explicit)
This commit is contained in:
volzhs 2015-06-29 02:56:38 +09:00
parent 584dd4db87
commit 903e6b37c0

View file

@ -47,8 +47,10 @@ public class PaymentsManager {
}
public PaymentsManager initService(){
Intent intent = new Intent("com.android.vending.billing.InAppBillingService.BIND");
intent.setPackage("com.android.vending");
activity.bindService(
new Intent("com.android.vending.billing.InAppBillingService.BIND"),
intent,
mServiceConn,
Context.BIND_AUTO_CREATE);
return this;