diff --git a/build/esyur.js b/build/esyur.js index 7d88583..5ec9778 100644 --- a/build/esyur.js +++ b/build/esyur.js @@ -2553,7 +2553,7 @@ function () { if (cs.size > 0) { offset += cs.size; length -= cs.size; - } else throw new Exception("Error while parsing ValueInfo structured data"); + } else throw new Error("Error while parsing ValueInfo structured data"); } rt.seal(); @@ -2641,7 +2641,7 @@ function () { if (cs.size > 0) { offset += cs.size; contentLength -= cs.size; - } else throw new Exception("Error while parsing structured data"); + } else throw new Error("Error while parsing structured data"); } rt.seal(); @@ -3572,8 +3572,8 @@ var _default = { //Array = 0x80, VarArray: 0x80, BoolArray: 0x81, - UInt8Array: 0x82, - Int8Array: 0x83, + Int8Array: 0x82, + UInt8Array: 0x83, CharArray: 0x84, Int16Array: 0x85, UInt16Array: 0x86, @@ -6024,15 +6024,15 @@ function (_IResource) { }, { key: "_invokeByArrayArguments", value: function _invokeByArrayArguments(index, args) { - if (this.destroyed) throw new Exception("Trying to access destroyed object"); - if (index >= this.instance.template.functions.length) throw new Exception("Function index is incorrect"); + if (this.destroyed) throw new Error("Trying to access destroyed object"); + if (index >= this.instance.template.functions.length) throw new Error("Function index is incorrect"); return this._p.connection.sendInvokeByArrayArguments(this._p.instanceId, index, args); } }, { key: "_invokeByNamedArguments", value: function _invokeByNamedArguments(index, namedArgs) { - if (this.destroyed) throw new Exception("Trying to access destroyed object"); - if (index >= this.instance.template.functions.length) throw new Exception("Function index is incorrect"); + if (this.destroyed) throw new Error("Trying to access destroyed object"); + if (index >= this.instance.template.functions.length) throw new Error("Function index is incorrect"); return this._p.connection.sendInvokeByNamedArguments(this._p.instanceId, index, namedArgs); } }, { @@ -6988,7 +6988,7 @@ function () { }, { key: "holdFor", value: function holdFor(src, offset, size, needed) { - if (size >= needed) throw new Exception("Size >= Needed !"); + if (size >= needed) throw new Error("Size >= Needed !"); this.data = _DataConverter["default"].combine(src, offset, size, this.data, 0, this.data.length); this.neededDataLength = needed; } diff --git a/package.json b/package.json index b338423..649eca0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "esyur", - "version": "1.3.7", + "version": "1.3.8", "description": "Distributed Object Framework", "main": "esyur.js", "scripts": { diff --git a/src/Data/Codec.js b/src/Data/Codec.js index 1c665ae..4f7d34f 100644 --- a/src/Data/Codec.js +++ b/src/Data/Codec.js @@ -442,7 +442,7 @@ export default class Codec { length -= cs.size; } else - throw new Exception("Error while parsing ValueInfo structured data"); + throw new Error("Error while parsing ValueInfo structured data"); } rt.seal(); @@ -536,7 +536,7 @@ export default class Codec { contentLength -= cs.size; } else - throw new Exception("Error while parsing structured data"); + throw new Error("Error while parsing structured data"); } diff --git a/src/Net/IIP/DistributedResource.js b/src/Net/IIP/DistributedResource.js index cebbc6b..b9266ea 100644 --- a/src/Net/IIP/DistributedResource.js +++ b/src/Net/IIP/DistributedResource.js @@ -152,20 +152,20 @@ export default class DistributedResource extends IResource _invokeByArrayArguments(index, args) { if (this.destroyed) - throw new Exception("Trying to access destroyed object"); + throw new Error("Trying to access destroyed object"); if (index >= this.instance.template.functions.length) - throw new Exception("Function index is incorrect"); + throw new Error("Function index is incorrect"); return this._p.connection.sendInvokeByArrayArguments(this._p.instanceId, index, args); } _invokeByNamedArguments(index, namedArgs) { if (this.destroyed) - throw new Exception("Trying to access destroyed object"); + throw new Error("Trying to access destroyed object"); if (index >= this.instance.template.functions.length) - throw new Exception("Function index is incorrect"); + throw new Error("Function index is incorrect"); return this._p.connection.sendInvokeByNamedArguments(this._p.instanceId, index, namedArgs); } diff --git a/src/Net/Sockets/NetworkBuffer.js b/src/Net/Sockets/NetworkBuffer.js index 8f89a67..d2aa35d 100644 --- a/src/Net/Sockets/NetworkBuffer.js +++ b/src/Net/Sockets/NetworkBuffer.js @@ -54,7 +54,7 @@ export default class NetworkBuffer { holdFor(src, offset, size, needed) { if (size >= needed) - throw new Exception("Size >= Needed !"); + throw new Error("Size >= Needed !"); this.data = DC.combine(src, offset, size, this.data, 0, this.data.length); this.neededDataLength = needed;