- if ($notify == 'Y') {
- // Transfer all neccessary data to the global $content array
- $content['start'] = generateDateTime($start, 2);
- $content['end'] = generateDateTime($end , 2);
- $content['now_t'] = generateDateTime(time(), 2);
- $content['title'] = $title;
- $content['id'] = $id; // id for the rallye details link
- $content['ref'] = '0';
- $content['refs'] = countSumTotalData($userid, 'user_data', 'userid', 'refid', true);
-
- // Load prices
- $content['prices'] = addReferalRallyePrices($id);
-
- // Determine min_users/prices tring
- $content['min_users'] = determineReferalRallyeMinimumUsers($min_users);
- $content['min_prices'] = determineReferalRallyeMinimumPrices($min_prices);
-
- // Send notification to member
- $message = loadEmailTemplate('member_rallye_notify', $content, $userid);
- sendEmail($userid, sprintf(getMessage('RALLYE_MEMBER_NOTIFY'), $title), $message);
+ // Notify the user?
+ if ($content['send_notify'] == 'Y') {
+ // Transfer all neccessary data to $content array
+ sendRallyeNotification($userid, $content);