Update proto.js

This commit is contained in:
nim from KA
2021-12-31 03:49:23 -05:00
committed by GitHub
parent 4a95bf74b0
commit 17a4e953c9

View File

@@ -97,7 +97,10 @@ Object.defineProperties(Array.prototype, {
class PointArray extends Array {
static convert(arr) {
arr.__proto__ = PointArray.prototype
if (!(arr instanceof PointArray)) {
arr.__proto__ = PointArray.prototype
}
return arr
}
}