Plugin Directory

Changeset 225205


Ignore:
Timestamp:
04/04/2010 01:01:14 PM (16 years ago)
Author:
nkuttler
Message:

fix broken merging of old and new options

File:
1 edited

Legend:

Unmodified
Added
Removed
  • custom-avatars-for-comments/trunk/inc/admin.php

    r225203 r225205  
    128128     */
    129129     function upgrade() {
    130         if ( version_compare( $this->get_option( 'version' ), '0.2.0.0' ) == -1 ) {
     130        if ( version_compare( $this->get_option( 'version' ), '0.2.0.0', '<' ) ) {
    131131            // If the plugin was already in use we assume the user added the
    132132            // select field by hand and hide it.
    133133            $newopts = $this->defaults();
    134             $this->options = array_merge( $this->options , $newopts );
     134            $this->options = array_merge( $newopts, $this->options );
    135135            $this->options['removeselect'] = '1';
    136             #var_dump( $this->options );
    137136            update_option( 'commentavatars', $this->options );
    138137        }
Note: See TracChangeset for help on using the changeset viewer.