Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
it should fix the issue with axiom error: ' AxiosError: maxContentLength size of -1 exceeded'. There is open issue related to it in axiom github: axios/axios#4806. In hb it causes following errors: [10/18/2023, 5:11:17 PM] [homebridge-tasmota-control] Device: 192.168.0.220 DGM Plug1, check state error: AxiosError: timeout of 10000ms exceeded, trying again. I'm not sure if value of 2000 will be enough
  • Loading branch information
mszag authored Oct 18, 2023
1 parent 3c320f4 commit 34020db
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ class tasmotaDevice {
this.axiosInstance = axios.create({
method: 'GET',
baseURL: url,
timeout: 10000
timeout: 10000,
maxContentLength: 2000
});

//check if the directory exists, if not then create it
Expand Down Expand Up @@ -248,4 +249,4 @@ class tasmotaDevice {
this.log.debug(`Device: ${this.host} ${accessoryName}, publish as external accessory.`);
this.startPrepareAccessory = false;
};
};
};

0 comments on commit 34020db

Please sign in to comment.