Early Bird Registration for DrupalCon Atlanta is now open! By registering during our Early Bird Registration window, you’ll save $100. This window ends on 19 January 2025 and will go by quickly, so don’t wait!
I got this error using "drupal-check" command.
$ drupal-check /c/Bitnami/drupal-8.7.10-0/apps/drupal/htdocs/modules/contrib/social_auth_mailru
2/7 [========>-------------------] 28%PHP Fatal error: Declaration of Drupal\social_auth_mailru\MailruAuthManager::getExtraDetails($url) must be compatible with Drupal\social_auth\AuthManager\OAuth2Manager::getExtraDetails($method = 'GET', $domain = NULL) in C:\Bitnami\drupal-8.7.10-0\apps\drupal\htdocs\modules\contrib\social_auth_mailru\src\MailruAuthManager.php on line 15
In MailruAuthManager.php there is passed "$url" argument to getExtraDetails function, but in OAuth2Manager.php in social_auth module, function is built like this getExtraDetails($method = 'GET', $domain = NULL)
, so arguments are not matching.
When I've commented these lines, I got another error:
$ drupal-check /c/Bitnami/drupal-8.7.10-0/apps/drupal/htdocs/modules/contrib/social_auth_mailru
2/7 [========>-------------------] 28%PHP Fatal error: Class Drupal\social_auth_mailru\MailruAuthManager contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (Drupal\social_api\AuthManager\OAuth2ManagerInterface::getAuthorizationUrl, Drupal\social_auth\AuthManager\OAuth2ManagerInterface::requestEndPoint) in C:\Bitnami\drupal-8.7.10-0\apps\drupal\htdocs\modules\contrib\social_auth_mailru\src\MailruAuthManager.php on line 15
I think that social_auth_mailru is wrong implemented with social_auth module.
Comment | File | Size | Author |
---|---|---|---|
#2 | wrong_social_auth_implementation-3100349-2.patch | 6.25 KB | Adev22 |
Issue fork social_auth_mailru-3100349
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:
Comments
Comment #2
Adev22 CreditAttribution: Adev22 at Google Code-In commentedhere's the patch, I've fixed the wrong implementation and got this message
Comment #3
Adev22 CreditAttribution: Adev22 at Google Code-In commentedComment #4
agrochal CreditAttribution: agrochal at Google Code-In commenteddrupal_set_message functions were replaced in this issue. Also, for the future, use dependency injection instead of calling it like this:
\Drupal\Core\Messenger\MessengerInterface::addMessage($this->t('Social Auth Mailru not configured properly. Contact site administrator.'), 'error');
."drupal-check" for me gives no errors.
Comment #5
gvsoComment #6
qzmenkoSocial Auth 2.x is not supported already. We need to update this module for compatibility with Social Auth 3.x and for 4.x after that.
Comment #9
qzmenko