Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#1426 closed defect (fixed)

patch: core.js String.prototype.pad_left sets/overrides global variable 'new_string'

Reported by: anonymous Owned by: adrian
Component: contrib.admin Version: magic-removal
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

The attached patch fixes that bug and adds some other small improvements.

contrib/admin/media/dateparse.js:
Check for existing methods before emulating
Array.prototype.indexOf
Array.prototype.filter
Upcoming versions of Mozilla might allready have these.
Added local variables for .length props for use in for-loops.

contrib/admin/media/core.js:
Added missing semicolons.
Added missing var statement.

contrib/admin/media/calendar.js:
Moved Calendar methods to prototype object.
Saves memory when multiple calendar instances are created.

contrib/admin/media/admin/RelatedObjectLookups.js:
Added missing semicolons.

Attachments (1)

admin-js-fixes.diff (5.8 KB) - added by anonymous 9 years ago.

Download all attachments as: .zip

Change History (2)

Changed 9 years ago by anonymous

comment:1 Changed 9 years ago by adrian

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

(In [2448]) Fixed #1426 -- Made several admin JavaScript improvements. Thanks, anonymous

Note: See TracTickets for help on using tickets.
Back to Top