forked from GNUsocial/gnu-social
I was trying to be smart by calling the same registration event as 'register' when doing EmailRegistration. However, that event is so low-bandwidth that plugins go fingerpoken in all the attributes and call methods on the passed-in action and things like that. So, now we just fall back to using the low-level stuff, catch any exceptions, and feel happy. Some stuff might not work, but it's generally anti-spam stuff more suited to public sites.
This plugin disables posting for accounts that do not have a
validated email address.
Example:
addPlugin('RequireValidatedEmail');
If you don't want to apply the validationr equirement to existing
accounts, you can specify a cutoff date to grandfather in users
registered prior to that timestamp.
addPlugin('RequireValidatedEmail',
array('grandfatherCutoff' => 'Dec 7, 2009');
You can also exclude the validation checks from OpenID accounts
connected to a trusted provider, by providing a list of regular
expressions to match their provider URLs.
For example, to trust WikiHow and Wikipedia users:
addPlugin('RequireValidatedEmailPlugin', array(
'trustedOpenIDs' => array(
'!^http://\w+\.wikihow\.com/!',
'!^http://\w+\.wikipedia\.org/!',
),
));
Todo:
* add a more visible indicator that validation is still outstanding
* test with XMPP, API posting