WordPress.org

Make WordPress Core

Opened 16 months ago

Closed 16 months ago

Last modified 16 months ago

#26027 closed defect (bug) (fixed)

jshint shouldn't throw errors:wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js

Reported by: seanchayes Owned by: nacin
Milestone: 3.8 Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: has-patch
Focuses: Cc:

Description

Resolving JSHint reported issues:

Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L6:C14] W117: 'tinymce' is not defined.
  var VK = tinymce.VK,
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L7:C22] W117: 'tinymce' is not defined.
    TreeWalker = tinymce.dom.TreeWalker,
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L10:C5] W117: 'tinymce' is not defined.
  tinymce.create('tinymce.plugins.wpView', {
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L187:C5] W117: 'tinymce' is not defined.
  tinymce.PluginManager.add( 'wpview', tinymce.plugins.wpView );
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L187:C42] W117: 'tinymce' is not defined.
  tinymce.PluginManager.add( 'wpview', tinymce.plugins.wpView );
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L11:C37] W098: 'url' is defined but never used.
    init : function( editor, url ) {
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L36:C57] W098: 'o' is defined but never used.
      editor.onSetContent.add( function( editor, o ) {
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L44:C80] W098: 'o' is defined but never used.
        editor.selection.onBeforeSetContent.add( function( selection, o ) {
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L98:C95] W098: 'o' is defined but never used.
      editor.onNodeChange.addToTop( function( editor, controlManager, node, collapsed, o ) {
Linting src/wp-includes/js/tinymce/plugins/wpview/editor_plugin_src.js ...ERROR
[L98:C92] W098: 'collapsed' is defined but never used.
      editor.onNodeChange.addToTop( function( editor, controlManager, node, collapsed, o ) {

Attachments (1)

26027.patch (1.7 KB) - added by seanchayes 16 months ago.

Download all attachments as: .zip

Change History (4)

@seanchayes16 months ago

comment:1 @seanchayes16 months ago

  • Keywords has-patch added

comment:2 @nacin16 months ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In 26201:

Fix JSHint errors in the wpview and wplink editor plugins.

props seanchayes.
fixes #26024, #26027.

comment:3 @nacin16 months ago

  • Milestone changed from Awaiting Review to 3.8

Moving fixed JSHint error tickets to 3.8.

Note: See TracTickets for help on using tickets.