Make WordPress Core


Ignore:
Timestamp:
03/17/2009 02:58:15 AM (16 years ago)
Author:
ryan
Message:

Move submit check into WP_Widget

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/widgets.php

    r10798 r10801  
    214214            }
    215215
    216             foreach( (array) $_POST['widget-' . $this->id_base] as $number => $new_instance ) {
     216            foreach ( (array) $_POST['widget-' . $this->id_base] as $number => $new_instance ) {
    217217                $new_instance = stripslashes_deep($new_instance);
    218218                $this->_set($number);
     219
     220                if ( !isset($new_instance['submit']) )
     221                    continue;
     222
    219223                if ( isset($all_instances[$number]) )
    220224                    $instance = $this->update($new_instance, $all_instances[$number]);
Note: See TracChangeset for help on using the changeset viewer.