Problem/Motivation
Error: Call to undefined method Facebook\Facebook::getAuthorizationUrl() in Drupal\social_post_facebook\FacebookPostAuthManager->getAuthorizationUrl() (line 76 of modules/contrib/social_post_facebook/src/FacebookPostAuthManager.php)
Steps to reproduce
- Enable and configure the module
- Go to your user profile and edit it
- Click on "Add account" under "Social Post Facebook"
Proposed resolution
The initSdk() function from social_post_facebook/src/Plugin/Network/FacebookPost.php is using the \Facebook\Facebook (from php-graph-sdk), it should use the \League\OAuth2\Client\Provider\Facebook class from the oauth2-facebook library.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 3258724.patch | 4.88 KB | eleonel |
Issue fork social_post_facebook-3258724
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3258724-message-error-call
changes, plain diff MR !1
Comments
Comment #3
eleonelI pushed a fix for that and now the error is gone, anyway still needs review.
Comment #4
j-barnes commentedTest and confirmed that I am no longer getting the above error. However after adding to the user I am getting the below prompt on Facebook and the app is never added. This might just be a non-issue and related to the settings in the actual Facebook app.
Comment #7
megakeegman commentedI have succeeded in adding a Facebook user to a Drupal account.
Comment #8
megakeegman commented