Skip to content

[FEATURE] Persist Bridge/Accessory/Service state #53

Open
@Shaquu

Description

@Shaquu

I looked a little and it looks like there is many lines of code which try to load accessories or services from prepared data but it's actually never saved (if I am not wrong...)!!!

node.debug("Looking for accessory with UUID '" + accessoryInformation.UUID + "'...");

    for (let i in bridge.bridgedAccessories) {

node.debug("Looking for service with UUID '" + serviceInformation.UUID + "'...");

    for (let i in accessory.services) {

There is a ready method to load accessories from directory in HAP-nodejs/AccessoryLoader.js/loadDirectory.

Now have to look if save/load is needed or we should just remove unnecessary code from our plugin which tries to find existing accessories.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions