@e-mc/request 0.12.16 → 0.12.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +4 -8
- package/README.md +5 -5
- package/http/adapter/index.js +1 -1
- package/index.js +2 -1
- package/package.json +4 -4
package/LICENSE
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
Copyright
|
|
1
|
+
Copyright 2025 An Pham
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
|
|
10
|
-
|
|
11
|
-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
7
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
|
|
10
10
|
## Interface
|
|
11
11
|
|
|
12
|
-
* [View Source](https://www.unpkg.com/@e-mc/types@0.12.
|
|
12
|
+
* [View Source](https://www.unpkg.com/@e-mc/types@0.12.18/lib/index.d.ts)
|
|
13
13
|
|
|
14
14
|
```typescript
|
|
15
15
|
import type { IModule, ModuleConstructor } from "./index";
|
|
@@ -256,12 +256,12 @@ instance.get("http://hostname/path/config.yml", options).then(data => {
|
|
|
256
256
|
|
|
257
257
|
## References
|
|
258
258
|
|
|
259
|
-
- https://www.unpkg.com/@e-mc/types@0.12.
|
|
260
|
-
- https://www.unpkg.com/@e-mc/types@0.12.
|
|
261
|
-
- https://www.unpkg.com/@e-mc/types@0.12.
|
|
259
|
+
- https://www.unpkg.com/@e-mc/types@0.12.18/lib/http.d.ts
|
|
260
|
+
- https://www.unpkg.com/@e-mc/types@0.12.18/lib/request.d.ts
|
|
261
|
+
- https://www.unpkg.com/@e-mc/types@0.12.18/lib/settings.d.ts
|
|
262
262
|
|
|
263
263
|
* https://www.npmjs.com/package/@types/node
|
|
264
264
|
|
|
265
265
|
## LICENSE
|
|
266
266
|
|
|
267
|
-
|
|
267
|
+
MIT
|
package/http/adapter/index.js
CHANGED
|
@@ -386,7 +386,7 @@ class HttpAdapter {
|
|
|
386
386
|
if (updating) {
|
|
387
387
|
this.updateProgress(0, this.contentLength);
|
|
388
388
|
}
|
|
389
|
-
if (enabled && this.instance.readExpect === 'always' && !empty) {
|
|
389
|
+
if (enabled && this.instance.readExpect === 'always' && !empty || opts.throwsEmpty) {
|
|
390
390
|
this.terminate("No data received");
|
|
391
391
|
return;
|
|
392
392
|
}
|
package/index.js
CHANGED
|
@@ -450,7 +450,7 @@ function finalizeBinArgs(instance, name, bin, args, opts, binOpts, cmd = []) {
|
|
|
450
450
|
const pattern = new RegExp(`^${leading}(?:=|$)`);
|
|
451
451
|
for (let i = 0; i < opts.length; ++i) {
|
|
452
452
|
if (pattern.test(opts[i])) {
|
|
453
|
-
opts.splice(i
|
|
453
|
+
opts.splice(i, 1);
|
|
454
454
|
break;
|
|
455
455
|
}
|
|
456
456
|
}
|
|
@@ -1491,6 +1491,7 @@ class Request extends module_1 {
|
|
|
1491
1491
|
silent ??= this.#singleton;
|
|
1492
1492
|
return new Promise((resolve, reject) => {
|
|
1493
1493
|
const init = [
|
|
1494
|
+
'--files-only=true',
|
|
1494
1495
|
'--links=false',
|
|
1495
1496
|
'--delete-excluded=false',
|
|
1496
1497
|
'--interactive=false',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@e-mc/request",
|
|
3
|
-
"version": "0.12.
|
|
3
|
+
"version": "0.12.18",
|
|
4
4
|
"description": "Request constructor for E-mc.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -16,11 +16,11 @@
|
|
|
16
16
|
"squared"
|
|
17
17
|
],
|
|
18
18
|
"author": "An Pham <anpham6@gmail.com>",
|
|
19
|
-
"license": "
|
|
19
|
+
"license": "MIT",
|
|
20
20
|
"homepage": "https://github.com/anpham6/e-mc#readme",
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@e-mc/module": "0.12.
|
|
23
|
-
"@e-mc/types": "0.12.
|
|
22
|
+
"@e-mc/module": "0.12.18",
|
|
23
|
+
"@e-mc/types": "0.12.18",
|
|
24
24
|
"combined-stream": "^1.0.8",
|
|
25
25
|
"js-yaml": "^4.1.1",
|
|
26
26
|
"picomatch": "^4.0.4",
|