Make WordPress Core

Changeset 26553


Ignore:
Timestamp:
12/03/2013 04:20:08 AM (10 years ago)
Author:
azaozz
Message:

Quicktags: fix int/string strict comparison, see #26046.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/js/quicktags.js

    r26212 r26553  
    374374            sel.text = content;
    375375            canvas.focus();
    376         } else if ( canvas.selectionStart || canvas.selectionStart === '0' ) { // FF, WebKit, Opera
     376        } else if ( canvas.selectionStart || canvas.selectionStart === 0 ) { // FF, WebKit, Opera
    377377            text = canvas.value;
    378378            startPos = canvas.selectionStart;
     
    473473            }
    474474            canvas.focus();
    475         } else if ( canvas.selectionStart || canvas.selectionStart === '0' ) { // FF, WebKit, Opera
     475        } else if ( canvas.selectionStart || canvas.selectionStart === 0 ) { // FF, WebKit, Opera
    476476            startPos = canvas.selectionStart;
    477477            endPos = canvas.selectionEnd;
Note: See TracChangeset for help on using the changeset viewer.