Changeset 1428 for trunk


Ignore:
Timestamp:
Jul 4, 2006, 12:53:26 AM (18 years ago)
Author:
plg
Message:

merge -r1426:1427 from branch 1.6 to trunk (bug 397 fixed: [...] type
comparison with operator "==").

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/include/functions.php

    r1284 r1428  
    608608      }
    609609
    610       if (!isset($insert[$dbfield]) or $insert[$dbfield] == '')
     610      if (!isset($insert[$dbfield]) or $insert[$dbfield] === '')
    611611      {
    612612        $query.= 'NULL';
     
    941941;';
    942942    list($representative) = mysql_fetch_array(pwg_query($query));
    943     $data = array('id' => $category_id,
    944                   'representative_picture_id' => $representative);
    945     array_push($datas, $data);
    946   }
    947 
    948   $fields = array('primary' => array('id'),
    949                   'update' => array('representative_picture_id'));
    950   mass_updates(CATEGORIES_TABLE, $fields, $datas);
     943
     944    array_push(
     945      $datas,
     946      array(
     947        'id' => $category_id,
     948        'representative_picture_id' => $representative,
     949        )
     950      );
     951  }
     952
     953  mass_updates(
     954    CATEGORIES_TABLE,
     955    array(
     956      'primary' => array('id'),
     957      'update' => array('representative_picture_id')
     958      ),
     959    $datas
     960    );
    951961}
    952962
Note: See TracChangeset for help on using the changeset viewer.