| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -7,7 +7,6 @@ const { | |||
| 7 | 7 | ObjectHasOwn, | |
| 8 | 8 | ObjectKeys, | |
| 9 | 9 | Proxy, | |
| 10 | - ReflectApply, | ||
| 11 | 10 | ReflectGetPrototypeOf, | |
| 12 | 11 | Symbol, | |
| 13 | 12 | } = primordials; | |
@@ -846,7 +845,7 @@ class Http2ServerResponse extends Stream { | |||
| 846 | 845 | this.writeHead(this[kState].statusCode); | |
| 847 | 846 | ||
| 848 | 847 | if (this[kState].closed || stream.destroyed) | |
| 849 | - ReflectApply(onStreamCloseResponse, stream, []); | ||
| 848 | + onStreamCloseResponse.call(stream); | ||
| 850 | 849 | else | |
| 851 | 850 | stream.end(); | |
| 852 | 851 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1960,7 +1960,7 @@ function shutdownWritable(callback) { | |||
| 1960 | 1960 | req.handle = handle; | |
| 1961 | 1961 | const err = handle.shutdown(req); | |
| 1962 | 1962 | if (err === 1) // synchronous finish | |
| 1963 | - return ReflectApply(afterShutdown, req, [0]); | ||
| 1963 | + return afterShutdown.call(req, 0); | ||
| 1964 | 1964 | } | |
| 1965 | 1965 | ||
| 1966 | 1966 | function finishSendTrailers(stream, headersList) { | |
@@ -2327,7 +2327,7 @@ class Http2Stream extends Duplex { | |||
| 2327 | 2327 | return; | |
| 2328 | 2328 | } | |
| 2329 | 2329 | debugStreamObj(this, 'shutting down writable on _final'); | |
| 2330 | - ReflectApply(shutdownWritable, this, [cb]); | ||
| 2330 | + shutdownWritable.call(this, cb); | ||
| 2331 | 2331 | ||
| 2332 | 2332 | if (this.session[kType] === NGHTTP2_SESSION_CLIENT && onClientStreamBodySentChannel.hasSubscribers) { | |
| 2333 | 2333 | onClientStreamBodySentChannel.publish({ stream: this }); | |
@@ -2741,8 +2741,7 @@ function doSendFD(session, options, fd, headers, streamOptions, err, stat) { | |||
| 2741 | 2741 | // response is canceled. The user code may also send a separate type | |
| 2742 | 2742 | // of response so check again for the HEADERS_SENT flag | |
| 2743 | 2743 | if ((typeof options.statCheck === 'function' && | |
| 2744 | - ReflectApply(options.statCheck, this, | ||
| 2745 | - [stat, headers, statOptions]) === false) || | ||
| 2744 | + options.statCheck.call(this, stat, headers, statOptions) === false) || | ||
| 2746 | 2745 | (this[kState].flags & STREAM_FLAGS_HEADERS_SENT)) { | |
| 2747 | 2746 | return; | |
| 2748 | 2747 | } | |
@@ -2801,7 +2800,7 @@ function doSendFileFD(session, options, fd, headers, streamOptions, err, stat) { | |||
| 2801 | 2800 | // response is canceled. The user code may also send a separate type | |
| 2802 | 2801 | // of response so check again for the HEADERS_SENT flag | |
| 2803 | 2802 | if ((typeof options.statCheck === 'function' && | |
| 2804 | - ReflectApply(options.statCheck, this, [stat, headers]) === false) || | ||
| 2803 | + options.statCheck.call(this, stat, headers) === false) || | ||
| 2805 | 2804 | (this[kState].flags & STREAM_FLAGS_HEADERS_SENT)) { | |
| 2806 | 2805 | tryClose(fd); | |
| 2807 | 2806 | return; | |
@@ -3633,9 +3632,9 @@ function getUnpackedSettings(buf, options = kEmptyObject) { | |||
| 3633 | 3632 | const settings = {}; | |
| 3634 | 3633 | let offset = 0; | |
| 3635 | 3634 | while (offset < buf.length) { | |
| 3636 | - const id = ReflectApply(readUInt16BE, buf, [offset]); | ||
| 3635 | + const id = readUInt16BE.call(buf, offset); | ||
| 3637 | 3636 | offset += 2; | |
| 3638 | - const value = ReflectApply(readUInt32BE, buf, [offset]); | ||
| 3637 | + const value = readUInt32BE.call(buf, offset); | ||
| 3639 | 3638 | switch (id) { | |
| 3640 | 3639 | case NGHTTP2_SETTINGS_HEADER_TABLE_SIZE: | |
| 3641 | 3640 | settings.headerTableSize = value; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -31,7 +31,6 @@ const { | |||
| 31 | 31 | ObjectFreeze, | |
| 32 | 32 | ObjectKeys, | |
| 33 | 33 | ObjectSetPrototypeOf, | |
| 34 | - ReflectApply, | ||
| 35 | 34 | Symbol, | |
| 36 | 35 | Uint32Array, | |
| 37 | 36 | } = primordials; | |
@@ -255,7 +254,7 @@ function ZlibBase(opts, mode, handle, { flush, finishFlush, fullFlush }) { | |||
| 255 | 254 | } | |
| 256 | 255 | } | |
| 257 | 256 | ||
| 258 | - ReflectApply(Transform, this, [{ autoDestroy: true, ...opts }]); | ||
| 257 | + Transform.call(this, { autoDestroy: true, ...opts }); | ||
| 259 | 258 | this[kError] = null; | |
| 260 | 259 | this.bytesWritten = 0; | |
| 261 | 260 | this._handle = handle; | |
@@ -681,7 +680,7 @@ function Zlib(opts, mode) { | |||
| 681 | 680 | processCallback, | |
| 682 | 681 | dictionary); | |
| 683 | 682 | ||
| 684 | - ReflectApply(ZlibBase, this, [opts, mode, handle, zlibDefaultOpts]); | ||
| 683 | + ZlibBase.call(this, opts, mode, handle, zlibDefaultOpts); | ||
| 685 | 684 | ||
| 686 | 685 | this._level = level; | |
| 687 | 686 | this._strategy = strategy; | |
@@ -724,7 +723,7 @@ function Deflate(opts) { | |||
| 724 | 723 | if (!(this instanceof Deflate)) { | |
| 725 | 724 | return deprecateInstantiation(Deflate, 'DEP0184', opts); | |
| 726 | 725 | } | |
| 727 | - ReflectApply(Zlib, this, [opts, DEFLATE]); | ||
| 726 | + Zlib.call(this, opts, DEFLATE); | ||
| 728 | 727 | } | |
| 729 | 728 | ObjectSetPrototypeOf(Deflate.prototype, Zlib.prototype); | |
| 730 | 729 | ObjectSetPrototypeOf(Deflate, Zlib); | |
@@ -733,7 +732,7 @@ function Inflate(opts) { | |||
| 733 | 732 | if (!(this instanceof Inflate)) { | |
| 734 | 733 | return deprecateInstantiation(Inflate, 'DEP0184', opts); | |
| 735 | 734 | } | |
| 736 | - ReflectApply(Zlib, this, [opts, INFLATE]); | ||
| 735 | + Zlib.call(this, opts, INFLATE); | ||
| 737 | 736 | } | |
| 738 | 737 | ObjectSetPrototypeOf(Inflate.prototype, Zlib.prototype); | |
| 739 | 738 | ObjectSetPrototypeOf(Inflate, Zlib); | |
@@ -742,7 +741,7 @@ function Gzip(opts) { | |||
| 742 | 741 | if (!(this instanceof Gzip)) { | |
| 743 | 742 | return deprecateInstantiation(Gzip, 'DEP0184', opts); | |
| 744 | 743 | } | |
| 745 | - ReflectApply(Zlib, this, [opts, GZIP]); | ||
| 744 | + Zlib.call(this, opts, GZIP); | ||
| 746 | 745 | } | |
| 747 | 746 | ObjectSetPrototypeOf(Gzip.prototype, Zlib.prototype); | |
| 748 | 747 | ObjectSetPrototypeOf(Gzip, Zlib); | |
@@ -751,7 +750,7 @@ function Gunzip(opts) { | |||
| 751 | 750 | if (!(this instanceof Gunzip)) { | |
| 752 | 751 | return deprecateInstantiation(Gunzip, 'DEP0184', opts); | |
| 753 | 752 | } | |
| 754 | - ReflectApply(Zlib, this, [opts, GUNZIP]); | ||
| 753 | + Zlib.call(this, opts, GUNZIP); | ||
| 755 | 754 | } | |
| 756 | 755 | ObjectSetPrototypeOf(Gunzip.prototype, Zlib.prototype); | |
| 757 | 756 | ObjectSetPrototypeOf(Gunzip, Zlib); | |
@@ -761,7 +760,7 @@ function DeflateRaw(opts) { | |||
| 761 | 760 | if (!(this instanceof DeflateRaw)) { | |
| 762 | 761 | return deprecateInstantiation(DeflateRaw, 'DEP0184', opts); | |
| 763 | 762 | } | |
| 764 | - ReflectApply(Zlib, this, [opts, DEFLATERAW]); | ||
| 763 | + Zlib.call(this, opts, DEFLATERAW); | ||
| 765 | 764 | } | |
| 766 | 765 | ObjectSetPrototypeOf(DeflateRaw.prototype, Zlib.prototype); | |
| 767 | 766 | ObjectSetPrototypeOf(DeflateRaw, Zlib); | |
@@ -770,7 +769,7 @@ function InflateRaw(opts) { | |||
| 770 | 769 | if (!(this instanceof InflateRaw)) { | |
| 771 | 770 | return deprecateInstantiation(InflateRaw, 'DEP0184', opts); | |
| 772 | 771 | } | |
| 773 | - ReflectApply(Zlib, this, [opts, INFLATERAW]); | ||
| 772 | + Zlib.call(this, opts, INFLATERAW); | ||
| 774 | 773 | } | |
| 775 | 774 | ObjectSetPrototypeOf(InflateRaw.prototype, Zlib.prototype); | |
| 776 | 775 | ObjectSetPrototypeOf(InflateRaw, Zlib); | |
@@ -779,7 +778,7 @@ function Unzip(opts) { | |||
| 779 | 778 | if (!(this instanceof Unzip)) { | |
| 780 | 779 | return deprecateInstantiation(Unzip, 'DEP0184', opts); | |
| 781 | 780 | } | |
| 782 | - ReflectApply(Zlib, this, [opts, UNZIP]); | ||
| 781 | + Zlib.call(this, opts, UNZIP); | ||
| 783 | 782 | } | |
| 784 | 783 | ObjectSetPrototypeOf(Unzip.prototype, Zlib.prototype); | |
| 785 | 784 | ObjectSetPrototypeOf(Unzip, Zlib); | |
@@ -837,7 +836,7 @@ function Brotli(opts, mode) { | |||
| 837 | 836 | this._writeState = new Uint32Array(2); | |
| 838 | 837 | handle.init(brotliInitParamsArray, this._writeState, processCallback); | |
| 839 | 838 | ||
| 840 | - ReflectApply(ZlibBase, this, [opts, mode, handle, brotliDefaultOpts]); | ||
| 839 | + ZlibBase.call(this, opts, mode, handle, brotliDefaultOpts); | ||
| 841 | 840 | } | |
| 842 | 841 | ObjectSetPrototypeOf(Brotli.prototype, Zlib.prototype); | |
| 843 | 842 | ObjectSetPrototypeOf(Brotli, Zlib); | |
@@ -846,7 +845,7 @@ function BrotliCompress(opts) { | |||
| 846 | 845 | if (!(this instanceof BrotliCompress)) { | |
| 847 | 846 | return deprecateInstantiation(BrotliCompress, 'DEP0184', opts); | |
| 848 | 847 | } | |
| 849 | - ReflectApply(Brotli, this, [opts, BROTLI_ENCODE]); | ||
| 848 | + Brotli.call(this, opts, BROTLI_ENCODE); | ||
| 850 | 849 | } | |
| 851 | 850 | ObjectSetPrototypeOf(BrotliCompress.prototype, Brotli.prototype); | |
| 852 | 851 | ObjectSetPrototypeOf(BrotliCompress, Brotli); | |
@@ -855,7 +854,7 @@ function BrotliDecompress(opts) { | |||
| 855 | 854 | if (!(this instanceof BrotliDecompress)) { | |
| 856 | 855 | return deprecateInstantiation(BrotliDecompress, 'DEP0184', opts); | |
| 857 | 856 | } | |
| 858 | - ReflectApply(Brotli, this, [opts, BROTLI_DECODE]); | ||
| 857 | + Brotli.call(this, opts, BROTLI_DECODE); | ||
| 859 | 858 | } | |
| 860 | 859 | ObjectSetPrototypeOf(BrotliDecompress.prototype, Brotli.prototype); | |
| 861 | 860 | ObjectSetPrototypeOf(BrotliDecompress, Brotli); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments