Better Table field value upgrade check (minor)
|Reported by:||cogmios||Owned by:|
line 1463 on /wp-admin/includes/upgrades.php is
preg_match("|".$tablefield->Field." ([^ ]*( unsigned)?)|i",$cfields[strtolower($tablefield->Field)], $matches); $fieldtype = $matches;
There is no check IF a $matches is found. If there is no match found an error will be displayed 'undefined index 1'. An Error message could be added here.
Can happen : if the sql code contains no spaces between the fieldname and the type it will generate the not found .
Change History (4)
- Component changed from General to Warnings/Notices
- Keywords reporter-feedback added
comment:3 c3mdigital — 7 months ago
- Keywords close added; needs-patch reporter-feedback removed
- Resolution set to worksforme
- Status changed from new to closed
- Type changed from enhancement to defect (bug)
- Version changed from 3.1 to 1.5