1/* vim: set ts=2 sw=2 sts=2 et: */ 2 3/** 4 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 5 * See https://www.x-cart.com/license-agreement.html for license details. 6 */ 7 8Object.getOwnPropertyDescriptors = function getOwnPropertyDescriptors(obj) { 9 var descriptors = {}; 10 for (var prop in obj) { 11 if (obj.hasOwnProperty(prop)) { 12 descriptors[prop] = Object.getOwnPropertyDescriptor(obj, prop); 13 } 14 } 15 return descriptors; 16}; 17 18Function.prototype.extend = function (proto) { 19 var superclass = this; 20 var constructor; 21 22 if (!proto.hasOwnProperty('constructor')) { 23 Object.defineProperty(proto, 'constructor', { 24 value: function () { 25 // Default call to superclass as in maxmin classes 26 superclass.apply(this, arguments); 27 }, 28 writable: true, 29 configurable: true, 30 enumerable: false 31 }); 32 } 33 constructor = proto.constructor; 34 35 constructor.prototype = Object.create(this.prototype, Object.getOwnPropertyDescriptors(proto)); 36 37 constructor.superclass = superclass.prototype; 38 39 return constructor; 40};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.