[wp-trac] [WordPress Trac] #49107: Coding Standards: src/js/media/views/settings.js
WordPress Trac
noreply at wordpress.org
Sat Jan 4 17:45:05 UTC 2020
#49107: Coding Standards: src/js/media/views/settings.js
-------------------------------+-------------------------------------------
Reporter: ankitmaru | Owner: SergeyBiryukov
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 5.4
Component: Media | Version: 5.3.2
Severity: normal | Resolution:
Keywords: has-patch dev- | Focuses: javascript, coding-standards
feedback |
-------------------------------+-------------------------------------------
Comment (by SergeyBiryukov):
Replying to [comment:3 adamsilverstein]:
> Instead, to clear this up and fix the linting error, we can move the
assignment above the logic check:
> {{{
> userSetting = $setting.data('userSetting');
> if ( userSetting ) {
> window.setUserSetting( userSetting, value );
> }
> }}}
That's exactly what [47029] does, unless I'm missing something?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/49107#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list