Make WordPress Core

Changeset 29190


Ignore:
Timestamp:
07/16/2014 05:55:00 PM (12 years ago)
Author:
azaozz
Message:

TinyMCE wpView: add noop() when returning early, fixes #28921

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/js/tinymce/plugins/wpview/plugin.js

    r29184 r29190  
    1111                toRemove = false,
    1212                firstFocus = true,
     13                _noop = function() { return false; },
    1314                cursorInterval, lastKeyDownNode, setViewCursorTries, focus, execCommandView;
    1415
    … …  
    156157        // Check if the `wp.mce` API exists.
    157158        if ( typeof wp === 'undefined' || ! wp.mce ) {
    158                 return;
     159                return {
     160                        getViewText: _noop,
     161                        setViewText: _noop,
     162                        getView: _noop
     163                };
    159164        }
    160165
Note: See TracChangeset for help on using the changeset viewer.