[wp-trac] [WordPress Trac] #22537: Fix balanceTags() docs and make the logic better readable

WordPress Trac noreply at wordpress.org
Thu Nov 22 14:05:56 UTC 2012


#22537: Fix balanceTags() docs and make the logic better readable
-----------------------------+-------------------------
 Reporter:  TobiasBg         |       Type:  enhancement
   Status:  new              |   Priority:  normal
Milestone:  Awaiting Review  |  Component:  General
  Version:                   |   Severity:  normal
 Keywords:  has-patch        |
-----------------------------+-------------------------
 The inline documentation of {{{balanceTags()}}} mixes up "and" and "or" in
 the first line. The function will does not require both {{{$force}}} and
 {{{get_option(...)}}} to be true, but just one. Apparently, some of the
 inline docs was already worked on in #19576, but the first line was left
 as-is.
 Also, the logic of the function is kind of hard to read with unnecessary
 boolean inversions.

 The attached patch fixed the docs and makes the function better readable.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22537>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list