Only send email or IM if preferences allow

Now email or IM notifications will only be sent if the user has those enabled in the preferences.  I also disabled DEBUG mode, so emails will actually be sent. BE PREPARED FOR THE SPAM!

Signed-off-by: ajthompson