Skip to content
This repository has been archived by the owner on Aug 3, 2019. It is now read-only.

email = null for com.sromku:simple-fb:4.1.1 #422

Open
walaagomaa18 opened this issue Apr 21, 2016 · 1 comment
Open

email = null for com.sromku:simple-fb:4.1.1 #422

walaagomaa18 opened this issue Apr 21, 2016 · 1 comment

Comments

@walaagomaa18
Copy link

Profile.Properties properties = new Profile.Properties.Builder()
.add(Profile.Properties.FIRST_NAME).add(Profile.Properties.GENDER)
.add(Profile.Properties.EMAIL).add(Profile.Properties.LAST_NAME)
.add(Profile.Properties.BIRTHDAY)
.add(Profile.Properties.PICTURE)
.build();
mSimpleFacebook.getProfile(properties,
new OnProfileListener() {
@OverRide
public void onException(@nonnull Throwable throwable) {

                }

                @Override
                public void onFail(String reason) {
                    // TODO Auto-generated method stub

                }

                @Override
                public void onComplete(@NonNull Profile profile) {

                    emailTxt.setText(profile.getEmail());
                    fnameTxt.setText(profile.getFirstName());
                    flnameTxt.setText(profile.getLastName());
                    String gender = profile.getGender();


                }
            });

profile.getEmail() is always null

@AllanWang
Copy link

Make sure you have sufficient permissions before calling this. It's working for me. The email might also need to be public or viewable to you.

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

No branches or pull requests

2 participants