WordPress.org

Make WordPress Core

Changeset 11492


Ignore:
Timestamp:
05/30/09 09:55:32 (5 years ago)
Author:
westi
Message:

Ensure the errors array is always defined so as to always have something to return

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/media.php

    r11463 r11492  
    382382    check_admin_referer('media-form'); 
    383383 
     384    $errors = array(); 
     385 
    384386    if ( isset($_POST['send']) ) { 
    385387        $keys = array_keys($_POST['send']); 
     
    408410            $errors[$attachment_id] = $post['errors']; 
    409411            unset($post['errors']); 
    410         } else { 
    411             $errors = array(); 
    412412        } 
    413413 
Note: See TracChangeset for help on using the changeset viewer.