[wp-trac] [WordPress Trac] #19067: Duplicate functionality in core: size_format() and wp_convert_bytes_to_hr()
WordPress Trac
wp-trac at lists.automattic.com
Thu Oct 27 14:15:57 UTC 2011
#19067: Duplicate functionality in core: size_format() and wp_convert_bytes_to_hr()
-------------------------+-----------------------------
Reporter: l3rady | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.2.1
Severity: trivial | Keywords: needs-patch
-------------------------+-----------------------------
I was looking through core to see if there was any function I could
utilize to format byte int to HR. I found the following two functions:
size_format() - /wp-includes/functions.php
wp_convert_bytes_to_hr() - /wp-admin/includes/template.php
They both do the same kind of thing but slightly differently. Is there any
need for `wp_convert_bytes_to_hr()`? from what I can see
`wp_convert_bytes_to_hr()` is only used once in core and where it is used
could be replaced with `size_format()`.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/19067>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list