Changeset 357 for trunk/lib/App.inc.php


Ignore:
Timestamp:
Jun 14, 2009 10:36:48 AM (15 years ago)
Author:
quinn
Message:

updated tests to work. updated email validation regex to include quote marks around name part. changed logmsg tmp dir name to use script_filename.

File:
1 edited

Legend:

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

    r348 r357  
    107107
    108108        // Don't email or sms duplicate messages that happen more often than this value (in seconds).
    109         'log_multiple_timeout' => 60,
     109        'log_multiple_timeout' => 61,
    110110
    111111        // Logging priority can be any of the following, or false to deactivate:
     
    556556
    557557        // Create tmp files so that we don't email and sms redundantly.
    558         $site_hash = md5(SITE_BASE);
     558        $site_hash = md5($_SERVER['SCRIPT_NAME']);
    559559        $temp_dir = $this->getParam('tmp_dir') . "/codebase_msgs_$site_hash/";
    560560        $temp_file = $temp_dir . $msg_id;
     
    567567            // Has this message been sent more recently than the timeout?
    568568            if ((time() - $msg_last_sent) < $this->getParam('log_multiple_timeout')) {
    569                 // This message was alreay sent recently
     569                // This message was already sent recently.
    570570                $send_notifications = false;
    571571            } else {
    572                 // Timeout has expired go ahead and send notifications again
     572                // Timeout has expired go ahead and send notifications again.
    573573                unlink($temp_file);
    574574            }
     
    597597        // NOTIFY SOMEONE
    598598        if ($send_notifications) {
    599 
    600599            // EMAIL ACTION
    601600            if ($this->getParam('log_email_priority') && $priority <= $this->getParam('log_email_priority')) {
Note: See TracChangeset for help on using the changeset viewer.