iobroker.airzone 2.0.1 → 2.0.2

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.
@@ -42,10 +42,7 @@ class AirzoneLocalApi {
42
42
 
43
43
  var url = "http://"+this.local_ip+":3000/api/v1/hvac";
44
44
  var systemId = this.system.id;
45
- this.logInfo("SystemId: "+systemId);
46
- //const data = JSON.stringify({"systemID":this.system?.id, "ZoneID":0});
47
45
  var data = '{\"systemID\":'+systemId+', \"ZoneID\":0}';
48
- this.logInfo(data);
49
46
  var response = await AsyncRequest.jsonPostRequest(url, data);
50
47
 
51
48
  var errors = response["errors"];
@@ -62,11 +59,15 @@ class AirzoneLocalApi {
62
59
 
63
60
  async sendUpdate(zoneid, key, value)
64
61
  {
62
+ if(this.system == undefined)
63
+ return false;
64
+
65
65
  try
66
66
  {
67
67
  var url = "http://"+this.local_ip+":3000/api/v1/hvac";
68
- var payload = '{\"systemID\":'+this.system?.id+', \"ZoneID\":'+zoneid+', \"'+key+'\":'+value+'}';
69
- var response = await AsyncRequest.jsonPutRequest(url, payload);
68
+ var systemId = this.system.id;
69
+ var data = '{\"systemID\":'+systemId+', \"ZoneID\":'+zoneid+', \"'+key+'\":'+value+'}';
70
+ var response = await AsyncRequest.jsonPutRequest(url, data);
70
71
  var errors = response["errors"];
71
72
  if(errors)
72
73
  {
@@ -80,6 +81,7 @@ class AirzoneLocalApi {
80
81
  catch (e) {
81
82
  this.logError('error during sendUpdate '+e+'\r\n'+e.stack);
82
83
  }
84
+ return false;
83
85
  }
84
86
  }
85
87
  module.exports = AirzoneLocalApi;
package/README.md CHANGED
@@ -7,15 +7,16 @@ Control and monitor airzone devices with ioBroker.
7
7
  [![Downloads](https://img.shields.io/npm/dm/iobroker.airzone.svg)](https://www.npmjs.com/package/iobroker.airzone)
8
8
  [![Stable](http://iobroker.live/badges/airzone-stable.svg)](http://iobroker.live/badges/airzone-stable.svg)
9
9
  [![installed](http://iobroker.live/badges/airzone-installed.svg)](http://iobroker.live/badges/airzone-installed.svg)
10
- [![Dependency Status](https://img.shields.io/david/SilentPhoenix11/iobroker.airzone.svg)](https://david-dm.org/SilentPhoenix11/iobroker.airzone)
11
10
  [![Known Vulnerabilities](https://snyk.io/test/github/SilentPhoenix11/ioBroker.airzone/badge.svg)](https://snyk.io/test/github/SilentPhoenix11/ioBroker.airzone)
12
11
  [![Build Status](https://travis-ci.com/SilentPhoenix11/ioBroker.airzone.svg?branch=master)](https://travis-ci.com/github/SilentPhoenix11/ioBroker.airzone)
13
12
 
14
- [![NPM](https://nodei.co/npm/iobroker.airzone.png?downloads=true)](https://nodei.co/npm/iobroker.airzone/)
13
+ ## Changelog
14
+ ### 2.0.2
15
+ * (SilentPhoenix11) Small fixes
15
16
 
16
- **Tests:**
17
+ ### 2.0.1
18
+ * (SilentPhoenix11) Small fixes
17
19
 
18
- ## Changelog
19
20
  ### 2.0.0
20
21
  * (SilentPhoenix11) Using the local API instead of cloud web service.
21
22
 
package/io-package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "common":{
3
3
  "name":"airzone",
4
- "version":"2.0.1",
4
+ "version":"2.0.2",
5
5
  "news":{
6
6
  "1.0.0":{
7
7
  "en": "initial release",
@@ -86,6 +86,18 @@
86
86
  "es": "Pequeñas correcciones",
87
87
  "pl": "Małe poprawki",
88
88
  "zh-cn": "小修正"
89
+ },
90
+ "2.0.2":{
91
+ "en": "Small fixes",
92
+ "de": "Kleine Korrekturen",
93
+ "ru": "Небольшие исправления",
94
+ "pt": "Pequenas correções",
95
+ "nl": "Kleine reparaties",
96
+ "fr": "Petits correctifs",
97
+ "it": "Piccole correzioni",
98
+ "es": "Pequeñas correcciones",
99
+ "pl": "Małe poprawki",
100
+ "zh-cn": "小修正"
89
101
  }
90
102
  },
91
103
  "title":"Airzone Local API",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"iobroker.airzone",
3
- "version":"2.0.1",
3
+ "version":"2.0.2",
4
4
  "description":"Airzone local api integration for ioBroker",
5
5
  "author":{
6
6
  "name":"Christian Schemmer",