Closed kioltk closed 4 months ago
Hello and thanks for reporting,
this is an interesting finding. One thing that comes to my mind, could you try: replacing the IS_IOS
constant in the code by Platform.OS === 'ios'
(basically inline the expression)? This should be the only place that matters.
async hasPlayServices(
options: HasPlayServicesParams = { showPlayServicesUpdateDialog: true },
): Promise<boolean> {
if (IS_IOS) {
return true;
} else {
if (options && options.showPlayServicesUpdateDialog === undefined) {
throw new Error(
'RNGoogleSignin: Missing property `showPlayServicesUpdateDialog` in options object for `hasPlayServices`',
);
}
return RNGoogleSignin.playServicesAvailable(options.showPlayServicesUpdateDialog);
}
}
Alternatively, you can try the version for sponsors which has this change included. I'm not saying it's the fix, but it could be.
edit: are you using metro bundler?
Thank you! :)
I am using metro bundler, correct
Looking into the main.jsbundle after changing IS_IOS
to Platform.os === 'ios'
, it does not emit the else block from the build, so I am not sure if this would help.
My current strategy is to remove js usage, but returning the package and pods dependencies, so I can be sure that the issue is with bundler and not with native binaries.
Sounds good! But the "else" block should not be there for ios I think, if you bundle with production settings.
Edit: assuming when you said emit you meant omit
Hey, updating on this
I removed all js implementation, only left the pods integration and AppStore Review Team approved it. So my assumption is that the issue was not about the native binary code, but the js bundled code.
Going to return the js code as it was and see if they say something about it
Makes no sense to me, but have to try it
About the omitting code, for some reason my bundler does not omit android code blocks when archiving production main.jsbundle. Sounds like it should, but does it really?
yes, the android code should be removed in iOS prod bundle. This is how metro does it: https://github.com/facebook/metro/blob/main/packages/metro-transform-plugins/src/inline-plugin.js#L148-L152
@kioltk hello I'm wondering, did you make some new discoveries in this regard? :)
thank you
I'm going to close this as there's nothing to do really on my side. Please comment if there's some news.
Hey,
We got our application release blocked cause of 'Google Play references in the binary'. Upon further investigation we found that this library is the single place where "google" and "play" can be mentioned in one place, so its kinda confusing. Our next step was to remove the library temporary, and we passed the review.
I will investigate it further in order to understand what triggers their false positive binary verification and will update this issue.
Feel free to close this issue, the motivation behind reporting it was: