0

I am integrating facebook in android I needed to disable SSO cause some old built in fb apps cause a problem..

I used this solution : https://stackoverflow.com/a/17673471/1862806

It is working good and i changed it to open for publish to request permissions too:

      session.openForPublish(new Session.OpenRequest(this).setCallback(fbCallback).setLoginBehavior(SessionLoginBehavior.SUPPRESS_SSO).setPermissions(PERMISSIONS));

If the user accepts the permissions while running the application, all is good, if he chooses to skip the publish permissions, i can't know in code, cause when i check using

    List<String> permissions = session.getPermissions();
    System.out.println(permissions);

I get permissions = [public_actions] as if user accepted them !!

I need to check if user skipped publish permissions in code while disabling SSO (it works with soo).. any idea how ?

thanks

Community
  • 1
  • 1
H.Android
  • 198
  • 1
  • 1
  • 12

1 Answers1

0

Looks like a potential bug, but you can always make a request to me/permissions using the Request class, and it will give you a list of permissions that the user has granted your app.

It's good to check this endpoint in general (probably once per startup) since the user can remove permissions via the Facebook website at any time.

Ming Li
  • 15,672
  • 3
  • 37
  • 35