Skip to content

OnResolve Not Called When Instagram #175

@ptahchiev

Description

@ptahchiev

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions