Skip to content

Commit

Permalink
feat: upgrade to node 20
Browse files Browse the repository at this point in the history
  • Loading branch information
bchelkowski committed Nov 24, 2023
1 parent 8cd8d02 commit 33ccd20
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18
20
2 changes: 1 addition & 1 deletion src/cli/arguments/field.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ export function getFieldArgumentDefinition(): [string, string] {
return ['[field]', 'Field of the data object that should be picked'];
}

export function getField<T>(args: ParsedArgumentsObject): string {
export function getField(args: ParsedArgumentsObject): string {
return args.field as string;
}
3 changes: 3 additions & 0 deletions src/utils/RokuRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ import { RokuPort } from './RokuPort.enum';
type FormDataType = { [key: string]: string | ReadStream };
type HeadersType = { [key: string]: string | string[] | undefined };

const agent = new http.Agent({ keepAlive: false });

export type RokuRequestOptions = {
auth?: {
password: string;
Expand Down Expand Up @@ -76,6 +78,7 @@ export default class RokuRequest {
private sendRequest(data: RokuRequestData): Promise<RokuRequestResponse> {
return new Promise((resolve, reject) => {
const options: http.RequestOptions = {
agent: agent,
headers: data.headers ?? {},
hostname: this.options.rokuIP,
method: this.options.method,
Expand Down

0 comments on commit 33ccd20

Please sign in to comment.