Skip to content

Commit

Permalink
fix: Fix some types (#810)
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk authored Nov 30, 2023
1 parent 71f3eca commit 694a1fc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/controller/model/endpoint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ const debug = {

type Mutable<T> = { -readonly [P in keyof T ]: T[P] };

interface ConfigureReportingItem {
export interface ConfigureReportingItem {
attribute: string | number | {ID: number; type: number};
minimumReportInterval: number;
maximumReportInterval: number;
reportableChange: number;
reportableChange: number | [number, number];
}

interface Options {
Expand Down Expand Up @@ -537,7 +537,7 @@ class Endpoint extends Entity {
}

public async read(
clusterKey: number | string, attributes: string[] | number [], options?: Options
clusterKey: number | string, attributes: (string | number)[], options?: Options
): Promise<KeyValue> {
const cluster = Zcl.Utils.getCluster(clusterKey);
options = this.getOptionsWithDefaults(options, true, Zcl.Direction.CLIENT_TO_SERVER, cluster.manufacturerCode);
Expand Down
2 changes: 1 addition & 1 deletion src/controller/model/group.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ class Group extends Entity {
}

public async read(
clusterKey: number | string, attributes: string[] | number [], options?: Options
clusterKey: number | string, attributes: (string | number)[], options?: Options
): Promise<void> {
options = this.getOptionsWithDefaults(options, Zcl.Direction.CLIENT_TO_SERVER);
const cluster = Zcl.Utils.getCluster(clusterKey);
Expand Down

0 comments on commit 694a1fc

Please sign in to comment.