This can be shortened to promise.then(…)
Or this:
Homey.devices.getDevices()
.then(f => {
return Object.values(f).filter((device) => device.driverUri === 'homey:app:com.mi.flora');
})
.then(devices => console.log(JSON.stringify(devices)));
This can be shortened to promise.then(…)
Or this:
Homey.devices.getDevices()
.then(f => {
return Object.values(f).filter((device) => device.driverUri === 'homey:app:com.mi.flora');
})
.then(devices => console.log(JSON.stringify(devices)));