Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion Parse/src/main/java/com/parse/ManifestInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,11 @@ private static boolean hasAnyGcmSpecificDeclaration() {
}

private static boolean isGooglePlayServicesAvailable() {
return Build.VERSION.SDK_INT >= 8 && getPackageInfo("com.google.android.gsf") != null;
Intent intent = new Intent(GcmRegistrar.REGISTER_ACTION);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we simplify this PR by deleting these two lines here and replacing it with the code you wrote for isGcmRegisterServiceAvailable?

intent.setPackage("com.google.android.gsf");
List<ResolveInfo> services = Parse.getApplicationContext().getPackageManager().
queryIntentServices(intent, 0);
return services != null && services.size() > 0;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's move this method into GcmRegistrar


private static ManifestCheckResult gcmSupportLevel() {
Expand Down