Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8675209
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T19:53:44+00:00 2026-06-12T19:53:44+00:00

Everything was working fine, until I wanted to check what happens if the user

  • 0

Everything was working fine, until I wanted to check what happens if the user clicks the Login with Facebook button with no internet connection available.

A toast showed up saying:

Login failed. Please contact the maker of this app and ask them to report issue #1118578 to Facebook.

In the logcat I have:

D/Facebook-authorize(2824): Login canceled by user.

I tried to get rid of this toast and display my own error message in the onCancel() method – but I can’t find a way to disable that toast.
When I enabled WiFi again, single sign on didn’t work anymore!

What could be the cause of this?

    private void fbLogin() {
    facebook.authorize(this, new String[] { "email" }, new DialogListener() {
        @Override
        public void onComplete(Bundle values) {
            app.save("fb_token", facebook.getAccessToken());
            app.save("fb_expire", facebook.getAccessExpires());
            mAsyncRunner.request("me", new meRequestListener());
        }
        @Override
        public void onFacebookError(FacebookError error) {}
        @Override
        public void onError(DialogError e) {}
        @Override
        public void onCancel() {}
    });
}

@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);

    facebook.authorizeCallback(requestCode, resultCode, data);
}

EDIT:

To answer my own question, removing android:launchMode="singleInstance" From the manifest in the <activity> resolved the #1118578 issue.

However, I do need the android:launchMode="singleInstance" for the twitter OAuth login, as the browser passes the data back to the activity via new Intent. If I do not provide android:launchMode="singleInstance" in the manifest, a new activity is launched and it does not recieve the OAuth verifier.

Is there any way around this, to use Facebook and Twitter login in the same activity?
The only solution I think of is to use a dummy activity for Twitter4j with singleInstance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T19:53:45+00:00Added an answer on June 12, 2026 at 7:53 pm

    My way to overcome this has been by changing the callback in twitter, from “twitter://callback” to “http://localhost/callback” and remove the android:launchMode=”singleInstance” and the twitter intent-filter from the manifest.

    I can still get the response in the WebView (rather than on the onResume() as before):

    yourwebview.setWebViewClient(new WebViewClient() {
      @Override
      public void onPageFinished(WebView view, String url) {
        // your_callback == http://localhost/callback
        if(url == null || !url.startsWith(your_callback))
          return;
    
        Uri         uri = Uri.parse(url);
        String      ov  = uri.getQueryParameter("oauth_verifier");
        AccessToken at  = null;
        ...
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Everything is working fine until I call the saveFile method (shown below) to write
I was using grails 1.3.4 for my project and everything was working fine until
I am using Eclipse Helios for Java. Everything was working fine until recently. The
today I started working with DirectX(D3D9), everything went fine until I created a Static-mesh
I'm following the tutorial here: http://guides.rubyonrails.org/getting_started.html Everything was working fine until I tried 8.1
I'm accessing an internal database using MATLAB's urlread command, everything was working fine until
Very new to .Net. Everything was working fine until I added <Tracking> to my
I am creating a template factory for my project, everything was working fine until
I used mouseup/down/move to manually implement jQuery.draggable functionality. Everything was working fine until I
I'm using the default xslt template for navigation, everything was working fine until I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.