Fixing problem with BuddyPress 2.0

This is a fix for work around a problem with BuddyPress.

Now works fine. Needs testing about Cron.