WordPress.org

Plugin Directory

Changeset 632368


Ignore:
Timestamp:
11/30/12 19:34:09 (17 months ago)
Author:
pento
Message:

Added option to only receive SVN update emails if something went wrong. Props @markel

Location:
automatic-updater/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • automatic-updater/trunk/admin.php

    r631867 r632368  
    133133 
    134134                    <p><input type="checkbox" id="svn" name="svn" value="1"<?php echo $checked; ?>> <label for="svn"><?php echo wp_kses( __( 'Run <tt>svn up</tt> hourly?', 'automatic-updater' ), array( 'tt' => array() ) ); ?></label></p> 
     135                    <p><input type="checkbox" id="svn-success-email" name="svn-success-email" value="1"<?php echo $checked; ?>> <label for="svn-success-email"><?php echo wp_kses( __( 'Send email on <tt>svn up</tt> success? Disabling this will cause notification emails to only be sent if the <tt>svn up</tt> fails.', 'automatic-updater' ), array( 'tt' => array() ) ); ?></label></p> 
    135136 
    136137                <?php 
  • automatic-updater/trunk/automatic-updater.php

    r632273 r632368  
    154154                                ), 
    155155                        'svn' => false, 
     156                        'svn-success-email' => true, 
    156157                        'debug' => false, 
    157158                        'next-development-update' => time(), 
     
    193194                                ); 
    194195        } 
     196 
     197        // Ability to only send SVN update emails on failure added in 0.8 
     198        if ( ! array_key_exists( 'svn-success-email', $this->options ) ) 
     199            $this->options['svn-success-email'] = true; 
    195200    } 
    196201 
     
    478483                return; 
    479484 
     485            // If we're only sending emails on failure, no need to continue 
     486            if( ! $this->options['svn-success-email'] ) 
     487                return; 
     488 
    480489            $message = esc_html__( 'We successfully upgraded from SVN!', 'automatic-updater' ); 
    481490            $message .= "<br><br>$update"; 
  • automatic-updater/trunk/readme.txt

    r632273 r632368  
    4646= 0.8 = 
    4747* ADDED: Retry limits, so broken updates won't keep trying to install 
     48* ADDED: Option to only receive SVN update emails if something went wrong 
    4849* FIXED: Some HTML tags in debug messages were being incorrectly stripped 
    4950* FIXED: Don't automatically enable Core updates on installs that seem to be coming from a repo 
Note: See TracChangeset for help on using the changeset viewer.