Opened 2 years ago
Last modified 2 years ago
#16842 closed defect (bug)
class-wp-list-table.php on line 140 — at Initial Version
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Comments | Version: | 3.1 |
| Severity: | normal | Keywords: | reporter-feedback |
| Cc: |
Description
3.1 recent install...
log in as admin...
then go to 'comments'...
the following error appears:
/home2/writinl4/public_html/angeltrivia/wp-admin/includes/class-wp-list-table.php on line 140
the if statement referenced is:
if ( !$argstotal_pages? && $argsper_page? > 0 ) {
$argstotal_pages? = ceil( $argstotal_items? / $argsper_page? );
}
I checked the variables, and they were set as so:
$argstotal_pages? = 0
$argsper_page? = 20
$argstotal_items? = ( array of items )
Uh.. can't divide an array!
So I changed the if calculation to:
if ( !$argstotal_pages? && $argsper_page? > 0 ) {
$argstotal_pages? = ceil( count( $argstotal_items? ) / $argsper_page? );
}
and it works...