Skip to content

Commit

Permalink
Merge pull request #8 from robvanoostenrijk/feature/zigbee2mqtt-v2
Browse files Browse the repository at this point in the history
Update against zigbee2mqtt extension signature changes
  • Loading branch information
Luligu authored Jan 4, 2025
2 parents c107702 + 4489ae2 commit 40f5e81
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dist/automations.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,15 @@ class InternalLogger {
}
}
class AutomationsExtension {
constructor(zigbee, mqtt, state, publishEntityState, eventBus, settings, logger) {
constructor(zigbee, mqtt, state, publishEntityState, eventBus, enableDisableExtension, restartCallback, addExtension, settings, logger) {
this.zigbee = zigbee;
this.mqtt = mqtt;
this.state = state;
this.publishEntityState = publishEntityState;
this.eventBus = eventBus;
this.enableDisableExtension = enableDisableExtension;
this.restartCallback = restartCallback;
this.addExtension = addExtension;
this.settings = settings;
this.logger = logger;
this.eventAutomations = {};
Expand Down
4 changes: 4 additions & 0 deletions src/automations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import type Zigbee from 'zigbee2mqtt/dist/zigbee';
import type MQTT from 'zigbee2mqtt/dist/mqtt';
import type State from 'zigbee2mqtt/dist/state';
import type EventBus from 'zigbee2mqtt/dist/eventBus';
import type Extension from 'zigbee2mqtt/dist/extension/extension';
import type Settings from 'zigbee2mqtt/dist/util/settings';
import type Logger from 'zigbee2mqtt/dist/util/logger';

Expand Down Expand Up @@ -232,6 +233,9 @@ class AutomationsExtension {
protected state: State,
protected publishEntityState: unknown,
protected eventBus: EventBus,
protected enableDisableExtension: (enable: boolean, name: string) => Promise<void>,
protected restartCallback: () => Promise<void>,
protected addExtension: (extension: Extension) => Promise<void>,
protected settings: typeof Settings,
protected logger: typeof Logger,
) {
Expand Down

0 comments on commit 40f5e81

Please sign in to comment.