signInWithProvider argument mismatch
I'm getting an argument mismatch on the signInWithProvider function, expected 4, received 2.
I'm using the v3 branch.
The Java code expects 4 arguments (3 + callback/promise). https://github.com/fullstackreact/react-native-firestack/blob/8db8b5040b90e990816ede8b749e24ca9a486a11/android/src/main/java/io/fullstack/firestack/auth/FirestackAuth.java#L161
But the JS code sends an object as first argument. https://github.com/fullstackreact/react-native-firestack/blob/8db8b5040b90e990816ede8b749e24ca9a486a11/lib/modules/auth/index.js#L154
The link function seems to be correctly updated:
https://github.com/fullstackreact/react-native-firestack/blob/8db8b5040b90e990816ede8b749e24ca9a486a11/lib/modules/auth/index.js#L137
Changing the code to this seems to work:
signInWithCredential(credential: any): Promise<Object> {
return promisify('signInWithProvider', FirestackAuth)(credential.provider, credential.token, credential.secret);
}
@ThaNarie This fixed it for me too, thanks. It should be accessToken in the JavaScript and in the Java as that's what it is in iOS and Web SDK. I've included this in my pull request (with docs updated for authToken too)