[wp-trac] [WordPress Trac] #43828: Add JSDoc ESLint script
WordPress Trac
noreply at wordpress.org
Mon Jul 20 02:40:37 UTC 2020
#43828: Add JSDoc ESLint script
-------------------------------------+-------------------------
Reporter: netweb | Owner: netweb
Type: task (blessed) | Status: assigned
Priority: normal | Milestone: 5.5
Component: Build/Test Tools | Version:
Severity: normal | Resolution:
Keywords: has-patch needs-testing | Focuses: javascript
-------------------------------------+-------------------------
Comment (by netweb):
@whyisjake A quick look at the [attachment:"43828.5.diff"] I discovered
that there are some unwanted changes in the `src/wp-includes/nav-menu.php`
file, the very last file when viewing the patch here on trac:
{{{
#!diff
Index: src/wp-includes/nav-menu.php
===================================================================
--- src/wp-includes/nav-menu.php (revision 48503)
+++ src/wp-includes/nav-menu.php (working copy)
@@ -837,21 +837,13 @@
if ( $original_object ) {
$menu_item->url = get_permalink(
$original_object->ID );
- /** This filter is documented in
wp-includes/post-template.php */
- $original_title = apply_filters(
'the_title', $original_object->post_title, $original_object->ID );
} else {
$menu_item->url = '';
- $original_title = '';
$menu_item->_invalid = true;
}
- if ( '' === $original_title ) {
- /* translators: %d: ID of a post.
*/
- $original_title = sprintf( __(
'#%d (no title)' ), $menu_item->object_id );
- }
+ $menu_item->title =
$menu_item->post_title;
- $menu_item->title = ( '' ===
$menu_item->post_title ) ? $original_title : $menu_item->post_title;
-
} elseif ( 'post_type_archive' ===
$menu_item->type ) {
$object = get_post_type_object(
$menu_item->object );
if ( $object ) {
}}}
The patch is hard to review here on Trac, I think this is a good candidate
to add a PR on GitHub, could you push up a PR and I'll review that there
please?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43828#comment:18>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list