mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-25 14:56:20 +00:00
9 lines
250 B
JavaScript
9 lines
250 B
JavaScript
|
/**
|
||
|
* Progressive enhancement for JS core- define things that are scheduled to
|
||
|
* appear in the standard anyway.
|
||
|
*/
|
||
|
|
||
|
if(!Array.prototype.last) Object.defineProperty(Array.prototype, 'last', {
|
||
|
value: function() { return this[this.length - 1] }
|
||
|
});
|