[wp-trac] [WordPress Trac] #32300: twemoji.js - validate nodes passed to parseNode

WordPress Trac noreply at wordpress.org
Fri May 8 03:50:41 UTC 2015


#32300: twemoji.js - validate nodes passed to parseNode
---------------------------+------------------------------
 Reporter:  peterwilsoncc  |       Owner:
     Type:  defect (bug)   |      Status:  new
 Priority:  normal         |   Milestone:  Awaiting Review
Component:  Formatting     |     Version:  4.2
 Severity:  normal         |  Resolution:
 Keywords:                 |     Focuses:  javascript
---------------------------+------------------------------

Comment (by peterwilsoncc):

 After further discussion with azaozz, was considered best to move the
 validation to wp.emoji.parse.

 It's worth unit testing, but I'm not sure how to go about it. I know it
 works with the following in the console.

 {{{#!js
 wp.emoji.parse( null );
 wp.emoji.parse();
 wp.emoji.parse( {} );
 wp.emoji.parse( [] );
 wp.emoji.parse( "" );
 wp.emoji.parse( "

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


More information about the wp-trac mailing list