- πΊπΈUnited States SocialNicheGuru
This would make this usable with social_auth_facebook, social_auth_x, social_auth_linkedin to name a few
To force user to accept legal documents (terms of service and privacy policy) I use the
entity legal module β
on my D8 site.
The user has to tick two check boxes to agree both legal documents.
When the user registers via facebook auth the authorization fails and the user don't get created.
Log shows this error message:
Could not create new user. Exception: Field field_accept_tos is unknown.
In general I observed that facebook auth has a problem with required fields in user registration form.
In other tests with this module some required fields on the registration form are simply ignored, and despite this user gets registered.
Instead of the current behavior, the user should be redirected to user registration form with prefilled fields provided by facebook. If user adds required aditional infomation, and sends the registration form, the user gets created.
Another resolution by entity legal module could be that a user gets the authenticated user role, which has the same privileges like an anonymous user. After accepting the required legal entities, he gets an additional role like "authenticated user authorized" or similar. Perhaps the additional role can be chosen on module configuration page.
Then social_auth and social_auth_facebook can work as usual and the privileges get only granted, when the user accepting the legal entities.
As long as the user has not accepted the legal entities, there should be shown a warning message like "you haven't accepted the legal documents yet, so your account is currently restricted. Go to your profile settings to accept them and get full access".
Perhaps the warning message and the link text are also configurable via module configuration page.
patch needed
Redirect user to register form to force filling out required fields
Active
4.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
This would make this usable with social_auth_facebook, social_auth_x, social_auth_linkedin to name a few