Compare commits

...

10 Commits

Author SHA1 Message Date
07a919b6ba docs: update changelog and header for version v1.4.9
All checks were successful
Release Workflow / detect-provider (push) Successful in 3s
Release Workflow / github-release (push) Has been skipped
Release Workflow / gitea-release (push) Successful in 2m48s
2025-03-29 10:11:25 +01:00
8618b90e33 docs: update platformio.ini for version v1.4.9 2025-03-29 10:11:25 +01:00
57723b5354 fix: enhance HTTP method handling in sendToApi function 2025-03-29 10:03:17 +01:00
d2be752175 docs: update changelog and header for version v1.4.8
All checks were successful
Release Workflow / detect-provider (push) Successful in 4s
Release Workflow / github-release (push) Has been skipped
Release Workflow / gitea-release (push) Successful in 2m46s
2025-03-29 07:58:12 +01:00
97a050ace8 docs: update platformio.ini for version v1.4.8 2025-03-29 07:58:12 +01:00
367e692c74
Merge pull request #30 from janecker/main
Fix memory leak issue in HTTPClient
2025-03-29 07:55:45 +01:00
926a21249b
Merge branch 'testing' into main 2025-03-29 07:55:33 +01:00
2635c19667 fix: improve HTTP client configuration and clear update documents after API calls 2025-03-29 07:52:49 +01:00
Jan Philipp Ecker
6cc4efca0a Fixes memory leak in HTTPClient by disabling connection reuse 2025-03-28 22:40:50 +01:00
1484a6b0da fix: update reload logic after removing and saving Bambu credentials for better cache handling 2025-03-27 19:13:57 +01:00
4 changed files with 37 additions and 7 deletions

View File

@ -1,5 +1,25 @@
# Changelog
## [1.4.9] - 2025-03-29
### Changed
- update platformio.ini for version v1.4.9
### Fixed
- enhance HTTP method handling in sendToApi function
## [1.4.8] - 2025-03-29
### Changed
- update platformio.ini for version v1.4.8
- Merge pull request #30 from janecker/main
- Merge branch 'testing' into main
### Fixed
- improve HTTP client configuration and clear update documents after API calls
- Fixes memory leak in HTTPClient by disabling connection reuse
- update reload logic after removing and saving Bambu credentials for better cache handling
## [1.4.7] - 2025-03-27
### Added
- add forced cache refresh after removing and saving Bambu credentials

View File

@ -70,8 +70,8 @@
document.getElementById('bambuStatusMessage').innerText = 'Bambu Credentials removed!';
// Reload with forced cache refresh after short delay
setTimeout(() => {
window.location.replace('/');
location.reload(true);
window.location.reload(true);
window.location.href = '/';
}, 1500);
} else {
document.getElementById('bambuStatusMessage').innerText = 'Error while removing Bambu Credentials.';
@ -116,8 +116,8 @@
document.getElementById('bambuStatusMessage').innerText = 'Bambu Credentials saved!';
// Reload with forced cache refresh after short delay
setTimeout(() => {
window.location.replace('/');
location.reload(true);
window.location.reload(true);
window.location.href = '/';
}, 1500);
} else {
document.getElementById('bambuStatusMessage').innerText = 'Error while saving Bambu Credentials.';

View File

@ -9,7 +9,7 @@
; https://docs.platformio.org/page/projectconf.html
[common]
version = "1.4.7"
version = "1.4.9"
to_old_version = "1.4.0"
##

View File

@ -94,13 +94,16 @@ void sendToApi(void *parameter) {
String octoToken = params->octoToken;
HTTPClient http;
http.setReuse(false);
http.begin(spoolsUrl);
http.addHeader("Content-Type", "application/json");
if (octoEnabled && octoToken != "") http.addHeader("X-Api-Key", octoToken);
int httpCode = http.PUT(updatePayload);
int httpCode;
if (httpType == "PATCH") httpCode = http.PATCH(updatePayload);
if (httpType == "POST") httpCode = http.POST(updatePayload);
else if (httpType == "POST") httpCode = http.POST(updatePayload);
else httpCode = http.PUT(updatePayload);
if (httpCode == HTTP_CODE_OK) {
Serial.println("Spoolman erfolgreich aktualisiert");
@ -111,6 +114,7 @@ void sendToApi(void *parameter) {
}
http.end();
vTaskDelay(50 / portTICK_PERIOD_MS);
// Speicher freigeben
delete params;
@ -165,6 +169,8 @@ bool updateSpoolTagId(String uidString, const char* payload) {
NULL // Task-Handle (nicht benötigt)
);
updateDoc.clear();
return true;
}
@ -201,6 +207,8 @@ uint8_t updateSpoolWeight(String spoolId, uint16_t weight) {
NULL // Task-Handle (nicht benötigt)
);
updateDoc.clear();
return 1;
}
@ -238,6 +246,8 @@ bool updateSpoolOcto(int spoolId) {
NULL // Task-Handle (nicht benötigt)
);
updateDoc.clear();
return true;
}