Changeset 114


Ignore:
Timestamp:
May 13, 2006 3:26:04 AM (18 years ago)
Author:
scdev
Message:

Update return statement of Email::send method.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/Email.inc.php

    r53 r114  
    279279
    280280        // Ensure message was successfully accepted for delivery.
    281         if (!mail($final_to, $this->_params['subject'], $final_body, $final_headers, $envelope_sender_header)) {
    282             App::logMsg(sprintf('Email failure with parameters: %s, %s, %s, %s', $this->_params['to'], $this->_params['subject'], str_replace("\r\n", ', ', $final_headers), $envelope_sender_header), LOG_NOTICE, __FILE__, __LINE__);
    283             return false;
    284         }
    285 
    286         return true;
     281        if (mail($final_to, $this->_params['subject'], $final_body, $final_headers, $envelope_sender_header)) {
     282            App::logMsg(sprintf('Email successfully sent to %s', $final_to), LOG_DEBUG, __FILE__, __LINE__);
     283            return true
     284        } else {
     285            App::logMsg(sprintf('Email failure with parameters: %s, %s, %s, %s', $final_to, $this->_params['subject'], str_replace("\r\n", '\r\n', $final_headers), $envelope_sender_header), LOG_NOTICE, __FILE__, __LINE__);
     286            return false;
     287        }
    287288    }
    288289
Note: See TracChangeset for help on using the changeset viewer.