Skip to content

Commit

Permalink
fix(hooks): accept signalNames string array
Browse files Browse the repository at this point in the history
  • Loading branch information
damienbutt committed Apr 16, 2022
1 parent 0ebdc43 commit a393494
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/hooks/useCrestronAnalogCollection/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ import { useCrestronPublishAnalogCollection } from "../useCrestronPublishAnalogC
import { useCrestronSubscribeAnalogCollection } from "../useCrestronSubscribeAnalogCollection";

export function useCrestronAnalogCollection(
signalName: string,
signalNames: string[],
callback?: AnalogStateCollectionCallback,
): [number[], AnalogAction[]] {
const state = useCrestronSubscribeAnalogCollection(signalName, callback);
const action = useCrestronPublishAnalogCollection(signalName);
const state = useCrestronSubscribeAnalogCollection(signalNames, callback);
const action = useCrestronPublishAnalogCollection(signalNames);

return [state, action];
}
Expand Down

0 comments on commit a393494

Please sign in to comment.