Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OnResolve Not Called When Instagram #175

Open
ptahchiev opened this issue Jun 12, 2024 · 0 comments
Open

OnResolve Not Called When Instagram #175

ptahchiev opened this issue Jun 12, 2024 · 0 comments

Comments

@ptahchiev
Copy link

I am using the LoginSocialInstagram and I see that it's not calling the onResolve function.

It works fine for Google and Facebook, but not for Instagram - my implementations are identical.

                              <LoginSocialInstagram
                                isOnlyGetToken
                                redirect_uri={`${process.env.REACT_APP_STOREFRONT_URL}/social/callback/instagram`}
                                client_id={process.env.REACT_APP_INSTAGRAM_APP_ID || ''}
                                client_secret={process.env.REACT_APP_INSTAGRAM_APP_SECRET || ''}
                                onResolve={({ provider, data }: IResolveParams) => {
                                    console.log('!!!!!!!!!!!!!!!!!!!!!!!');
                                    debugger
                                    this.saveSocialToken(provider, data);
                                }}
                                onReject={(err: any) => {
                                  console.error(err)
                                }}
                              >
                                <InstagramLoginButton className="rounded-4">
                                    <span>Connect Instagram</span>
                                </InstagramLoginButton>
                              </LoginSocialInstagram>

  • I click on the button
  • A popup opens and I click on "Allow Access"
  • The access is given, the user is redirected to the url in redirect_uri in the popup
  • Then the popup closes and the onResolve is not called in the host window.

For Facebook and Google the host window calls the onResolve

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant