Make WordPress Core

Ticket #21845: 21845.3.patch

File 21845.3.patch, 1.3 KB (added by chriscct7, 8 years ago)

Fixes fatal error and corrects formatting

  • wp-admin/js/edit-comments.js

     
    313313        },
    314314
    315315        toggle : function(el) {
    316                 if ( $(el).css('display') != 'none' )
    317                         $(el).find('a.vim-q').click();
     316                var replyrow = $('#replyrow');
     317
     318                if ( $(el).css('display') != 'none' ) {
     319
     320                        //Open reply box if it is not already open
     321                        if ( replyrow.parent().is('#com-reply') ) {
     322                                $(el).find('a.vim-q').click();
     323                        } else {
     324                                if ( window.confirm( adminCommentsL10n.warnQuickEdit ) ) {
     325                                        $(el).find('a.vim-q').click();
     326                                }
     327                        }
     328                }
    318329        },
    319330
    320331        revert : function() {
  • wp-includes/script-loader.php

     
    437437                        'hotkeys_highlight_first' => isset($_GET['hotkeys_highlight_first']),
    438438                        'hotkeys_highlight_last' => isset($_GET['hotkeys_highlight_last']),
    439439                        'replyApprove' => __( 'Approve and Reply' ),
    440                         'reply' => __( 'Reply' )
     440                        'reply' => __( 'Reply' ),
     441                        'warnQuickEdit' => __( 'Are you sure you want to start quick editing a new comment?' ),
    441442                ) );
    442443
    443444                $scripts->add( 'xfn', "/wp-admin/js/xfn$suffix.js", array('jquery'), false, 1 );