[wp-trac] [WordPress Trac] #29176: Wrong length (duration) in wp_read_video_metadata()

WordPress Trac noreply at wordpress.org
Thu Sep 11 14:31:06 UTC 2014


#29176: Wrong length (duration) in wp_read_video_metadata()
--------------------------+-----------------------------
 Reporter:  jrf           |       Owner:  wonderboymusic
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  4.1
Component:  Media         |     Version:  3.6
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |     Focuses:
--------------------------+-----------------------------

Comment (by wonderboymusic):

 `length_formatted` is set to the value of `playtime_string`, which is a
 prop returned by `getID3::analyze()` - it is the only value we ever read
 directly. `length` is just there in case you want to format your own time
 string. Without `round()`, the values can differ: `length` would be 46
 while `length_formatted` would be `45`. I vote for consistency with the
 values, since `ceil()` was already converting the float, there was no
 chance for the user to make that choice.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/29176#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list