romatroskin / social_share_plugin

Social Share to Facebook and Instagram Flutter plugin.
BSD 2-Clause "Simplified" License
41 stars 86 forks source link

Share Facebook Link don't call callback onSuccess function. #33

Open truonguit2010 opened 4 years ago

truonguit2010 commented 4 years ago

Hi, Step 1: I just checked your facebook share link function and it don't call callback onSuccess function. Step 2: I add registrar.addActivityResultListener(plugin); in registerWith function, and it work OK now. [

Screen Shot 2020-05-14 at 15 54 03

](url)

Is it right?

stannyc commented 4 years ago

I do also facing the same problem with shareToFeedFacebook() method.... here's my code:

                      await SocialSharePlugin.shareToFeedFacebook(
                          path: file.path,
                          onSuccess: (x) async {
                            print(x);
                            print('FACEBOOK SUCCESS');
                            return;
                          },
                          onCancel: () {
                            print('FACEBOOK CANCELLED');
                            return;
                          },
                          onError: (error) {
                            print('FACEBOOK ERROR $error');
                            return;
                          });

nothing is printed..