Last modified: 2014-01-08 17:09:12 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T52322, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 50322 - Stop using _this, use this
Stop using _this, use this
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
UploadWizard (Other open bugs)
unspecified
All All
: Lowest enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
: javascript
Depends on:
Blocks: 49987
  Show dependency treegraph
 
Reported: 2013-06-27 21:24 UTC by Mark Holmquist
Modified: 2014-01-08 17:09 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Mark Holmquist 2013-06-27 21:24:16 UTC
UploadWizard has an _epidemic_ unnecessary use of "_this". Let's start using "self" or similar where necessary and "this" where possible.
Comment 1 Gerrit Notification Bot 2013-08-23 00:56:00 UTC
Change 80523 had a related patch set uploaded by MarkTraceur:
Loads of work on jshint fixes

https://gerrit.wikimedia.org/r/80523
Comment 2 Gerrit Notification Bot 2013-08-27 00:34:42 UTC
Change 80523 merged by jenkins-bot:
Loads of work on jshint fixes

https://gerrit.wikimedia.org/r/80523
Comment 3 Krinkle 2013-09-30 16:03:56 UTC
Still a few more:

$ ack _this -Q -c | grep -v ':0'
resources/jquery/jquery.mwCoolCats.js:14
resources/mw.UploadWizard.js:2
resources/mw.UploadWizardDeed.js:70
resources/mw.UploadWizardDescription.js:14
resources/mw.UploadWizardDetails.js:230
resources/mw.UploadWizardLicenseInput.js:65
resources/mw.UploadWizardUpload.js:83
resources/mw.UploadWizardUploadInterface.js:92
Comment 4 apsdehal 2014-01-08 16:57:17 UTC
Should I work on this, or you want to leave it as it is?
Comment 5 Mark Holmquist 2014-01-08 17:06:01 UTC
I wouldn't mind you fixing it - I think mostly they got fixed in the jshint patches, so it shouldn't be necessary, but I wouldn't mind fixing this bug and then moving on to the rest of the jshint things.
Comment 6 Mark Holmquist 2014-01-08 17:09:12 UTC
Also notably we changed the policy from being "self" to basically a descriptive word for whatever "this" is in the appropriate scope - e.g. "licenseInput" in a LicenseInput context, "wizard" in an UploadWizard context, "upload" in an UploadWizardUpload context, etc. etc..

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links