#55137 closed defect (bug) (duplicate)
WP_Query max_num_pages returns float instead of int
Reported by: | bkrnetic | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Query | Keywords: | needs-patch |
Focuses: | docs | Cc: |
Description
The docs say that WP_Query max_num_pages
property returns int but it returns float.
Change History (4)
#2
@
3 years ago
- Keywords needs-patch added; dev-feedback removed
The same goes for other related queries:
- WP_Network_Query
- WP_Comment_Query
- WP_Site_Query
- …
Note: See
TracTickets for help on using
tickets.
Hello and thank you for opening this ticket,
Theoretically, that's right:
ceil
will return a float and not an integer.https://www.php.net/manual/function.ceil.php