Skip to content
This repository was archived by the owner on Mar 16, 2025. It is now read-only.

Commit e2d259c

Browse files
authored
Merge pull request #14 from hatsyjs/drop-a-iterable
Drop `a-iterable` and `call-thru` dependencies
2 parents 9a6f983 + 4389510 commit e2d259c

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

package.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,6 @@
5050
},
5151
"dependencies": {
5252
"@hatsy/http-header-value": "^3.4.0",
53-
"@proc7ts/a-iterable": "^2.8.0",
54-
"@proc7ts/call-thru": "^4.1.0",
5553
"@proc7ts/primitives": "^1.2.0"
5654
},
5755
"engines": {

src/http/util/add-response-header.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
* @packageDocumentation
33
* @module @hatsy/hatsy
44
*/
5-
import { mapIt } from '@proc7ts/a-iterable';
65
import { arrayOfElements, elementOrArray } from '@proc7ts/primitives';
76
import { ServerResponse } from 'http';
87

@@ -17,7 +16,7 @@ import { ServerResponse } from 'http';
1716
*/
1817
export function addResponseHeader(response: ServerResponse, name: string, value: string): void {
1918

20-
const oldValues = mapIt(arrayOfElements(response.getHeader(name)), String);
19+
const oldValues = arrayOfElements(response.getHeader(name)).map(String);
2120
const newValues = elementOrArray(new Set<string>(oldValues).add(value))!;
2221

2322
response.setHeader(name, newValues);

0 commit comments

Comments
 (0)