WordPress.org

Plugin Directory

Changeset 267011 for edit-flow


Ignore:
Timestamp:
07/24/10 22:09:51 (7 years ago)
Author:
sbressler
Message:

E-mail notifications now excluded for auto-drafts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • edit-flow/trunk/php/notifications.php

    r256786 r267011  
    4747        global $current_user, $edit_flow; 
    4848         
    49         // No need to notify if it's a revision 
    50         // Also no need to email if post status wasn't changed 
    51         if ($new_status != 'inherit' && $old_status != $new_status) { 
     49        // No need to notify if it's a revision, auto-draft, or if post status wasn't changed 
     50        $ignored_statuses = array( $old_status, 'inherit', 'auto-draft' ); 
     51        if ( !in_array($new_status, $ignored_statuses) ) { 
    5252             
    5353            // Get current user 
Note: See TracChangeset for help on using the changeset viewer.