I have a system where users are able to pair multiple accounts with a single 
profile. As an example, consider a bank where one might have multiple accounts 
that they could pair (and thus access) with a single username and password.

Currently, if a user attempts to pair an account that is already paired, they 
receive an error because an account may only be paired with a single profile. 
To pair it, they would need to log into the profile the account it paired with, 
un-pair it, return to the desired profile and then complete the pairing.

This is process is tedious and occasionally impossible however. Sometimes users 
don't know or remember that they paired the account previously or they may no 
longer have access to the email address that they used for the profile that the 
account is paired with.

Thus, I am updating the system to allow a user to force an account to be paired 
(this un-pairs it from whatever profile it is currently paired with and then 
completes the pairing with the current profile).

This update is in place and works. The gotcha I have run into is the small 
chance that a user may be logged in and browsing an account at the very moment 
that another user un-pairs the account. The chances of this happening are 
exceptionally slim since any profile that an account might previously be paired 
with would also be owned by the same user, but I still need to cover it. (It 
could be a spouse or someone else that they had given access to.)

I currently set the account in the user's session upon logging in, so the 
change wouldn't be updated until the user logs out and then back in. Any ideas 
on how to update the change other than hitting the database on every page load 
to check if the profile still has access to the account in use?

_______________________________________________

UPHPU mailing list
[email protected]
http://uphpu.org/mailman/listinfo/uphpu
IRC: #uphpu on irc.freenode.net

Reply via email to