Changeset 1583

Show
Ignore:
Timestamp:
04/22/08 08:04:44 (4 weeks ago)
Author:
misja
Message:

Misja Hoebe <misja@curverider.co.uk> Fixes #343, The code within this check is only executed if the *community owner* has email notification turned on.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • devel/mod/community/lib/community_member_add.php

    r1581 r1583  
    2727                  } 
    2828                    $run_result[]= sprintf(__gettext("You joined %s."), stripslashes($friend->name)); 
    29                     if (user_flag_get("emailnotifications", $owner->ident)) { 
    30                         $message_body= sprintf(__gettext("%s has joined %s!\n\nTo visit this user's profile, click on the following link:\n\n\t%s\n\nTo view all community members, click here:\n\n\t%s\n\nRegards,\n\nThe %s team."), $_SESSION['name'], $friend->name, $CFG->wwwroot . user_info("username", $USER->ident) . "/", $CFG->wwwroot . $friend->username . "/community/members", $CFG->sitename); 
    31                         $title= sprintf(__gettext("New %s member"), $friend->name); 
    32                         notify_user($owner->ident, $title, $message_body); 
    33                         plugin_hook("community:member","publish",$f); 
    34                     } 
     29 
     30                    $message_body= sprintf(__gettext("%s has joined %s!\n\nTo visit this user's profile, click on the following link:\n\n\t%s\n\nTo view all community members, click here:\n\n\t%s\n\nRegards,\n\nThe %s team."), $_SESSION['name'], $friend->name, $CFG->wwwroot . user_info("username", $USER->ident) . "/", $CFG->wwwroot . $friend->username . "/community/members", $CFG->sitename); 
     31                    $title= sprintf(__gettext("New %s member"), $friend->name); 
     32                    notify_user($owner->ident, $title, $message_body); 
     33                    plugin_hook("community:member","publish",$f); 
     34 
    3535                } else 
    3636                    if ($friend->moderation == "yes") {