Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Currently the user who wants to deauthorize the facebook app gets informed to set a password, irrespective if password is set or not. I would like to check if the user has already set the password, then he should be allowed to disconnect his account from Facebook or if not, he needs to set a password first.
Comment | File | Size | Author |
---|---|---|---|
#3 | fboauth-check-password-before-deauthorize-2074563-3.patch | 1.98 KB | osopolar |
#1 | fboauth-check-password-before-deauthorize-2074563-1.patch | 1.97 KB | osopolar |
Comments
Comment #1
osopolarPatch attached.
Users who already have set their password don't have to bother about the current message and for all others it is more clear what to do first.
BTW: This also avoids the meaningless phrase "normal password":
Comment #2
quicksketchThanks, this looks pretty good to me. Two suggestions:
- Can't we already check if a user has a password by checking the $account object?
- In the second call to t(), move the
<strong>
tags outside the translated string, since it's now before and after the whole string rather than in the middle.I'm not really sure about "normal password" vs. "Your Site Name password". I don't think the latter is any more clear than the former. Then again, I don't know if either phrase is going to be easy to understand anyway. In any case, it's an edge-case scenario and this new approach only shows the message when needed, so I don't think it matters too much exactly what it says. Hiding the message will save most users any confusion.
Comment #3
osopolarfixes:
* use
$account->pass
.* move the
<strong>
tags outside the translated string* New message text:
If deauthorized, you will no longer be able to use Facebook to log into this account and must use your username and password as set in your <a href="!profile_url">user profile settings</a>.
... now the user is able quickly verify/change his account settings before disconnecting the facebook account.Comment #4
quicksketchExcellent! I'll review this for commit when I'm next working on the module.