iobroker.device-watcher 2.14.5 → 2.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/tools.js CHANGED
@@ -131,7 +131,7 @@ async function checkLastContact(adaptr) {
131
131
  deviceData.deviceStateSelectorHMRPC,
132
132
  deviceData.rssiPeerSelectorHMRPC,
133
133
  );
134
- if (contactData !== undefined || contactData !== null) {
134
+ if (contactData !== undefined && contactData !== null) {
135
135
  deviceData.LastContact = contactData[0];
136
136
  deviceData.Status = contactData[1];
137
137
  deviceData.linkQuality = contactData[2];
package/main.js CHANGED
@@ -358,7 +358,7 @@ class DeviceWatcher extends utils.Adapter {
358
358
  await this.renewDeviceData(id, state);
359
359
  }
360
360
  } catch (error) {
361
- this.log.error(`Issue at state change: ${error}`);
361
+ this.log.error(`Issue at state change: ${id}`);
362
362
  }
363
363
  } else {
364
364
  // The state was deleted
@@ -737,7 +737,7 @@ class DeviceWatcher extends utils.Adapter {
737
737
  break;
738
738
  default:
739
739
  if (deviceBatteryState === undefined) {
740
- if (deviceBatteryState === undefined) {
740
+ if (deviceLowBatState !== undefined) {
741
741
  if (deviceLowBatState !== true && deviceLowBatState !== 'NORMAL' && deviceLowBatState !== 1) {
742
742
  batteryHealth = 'ok';
743
743
  isBatteryDevice = true;
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "iobroker.device-watcher",
3
- "version": "2.14.5",
3
+ "version": "2.15.0",
4
4
  "description": "Watchdog for devices",
5
- "author": {
6
- "name": "Christian Behrends",
7
- "email": "mail@christian-behrends.de"
8
- },
5
+ "author": "Christian Behrends <mail@christian-behrends.de>",
6
+ "contributors": [
7
+ "iobroker-community-adapters <iobroker-community-adapters@gmx.de>"
8
+ ],
9
9
  "homepage": "https://github.com/iobroker-community-adapters/ioBroker.device-watcher",
10
10
  "license": "MIT",
11
11
  "keywords": [
@@ -37,14 +37,10 @@
37
37
  "@iobroker/adapter-dev": "^1.5.0",
38
38
  "@iobroker/eslint-config": "^2.1.0",
39
39
  "@iobroker/testing": "^5.2.2",
40
- "@types/node": "^24.10.0",
40
+ "@types/node": "^24.10.4",
41
41
  "@types/node-schedule": "^2.1.8",
42
- "@typescript-eslint/eslint-plugin": "^8.46.3",
43
- "@typescript-eslint/parser": "^8.46.2",
44
- "eslint": "^9.39.1",
45
- "eslint-config-prettier": "^10.1.5",
46
- "eslint-plugin-prettier": "^5.5.4",
47
- "prettier": "^3.6.2",
42
+ "@typescript-eslint/eslint-plugin": "^8.52.0",
43
+ "@typescript-eslint/parser": "^8.48.1",
48
44
  "typescript": "~5.9.3"
49
45
  },
50
46
  "main": "main.js",