mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Panel Plugins: Change array methods from read-only to writable (#71315)
This commit is contained in:
parent
b39c8aec6c
commit
864bf28a55
@ -19,33 +19,33 @@ if (!Object.getOwnPropertyDescriptor(Array.prototype, 'toArray')) {
|
||||
value: function (idx: number): any {
|
||||
return (this as any)[idx];
|
||||
},
|
||||
writable: false,
|
||||
writable: true,
|
||||
enumerable: false,
|
||||
configurable: false,
|
||||
configurable: true,
|
||||
},
|
||||
set: {
|
||||
value: function (idx: number, value: any) {
|
||||
(this as any)[idx] = value;
|
||||
},
|
||||
writable: false,
|
||||
writable: true,
|
||||
enumerable: false,
|
||||
configurable: false,
|
||||
configurable: true,
|
||||
},
|
||||
add: {
|
||||
value: function (value: any) {
|
||||
(this as any).push(value);
|
||||
},
|
||||
writable: false,
|
||||
writable: true,
|
||||
enumerable: false,
|
||||
configurable: false,
|
||||
configurable: true,
|
||||
},
|
||||
toArray: {
|
||||
value: function () {
|
||||
return this;
|
||||
},
|
||||
writable: false,
|
||||
writable: true,
|
||||
enumerable: false,
|
||||
configurable: false,
|
||||
configurable: true,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user