Log the reason for the config read to fail

This commit is contained in:
2026-02-28 10:06:00 -05:00
parent d90d5b9550
commit 8135f0e248

View File

@@ -76,7 +76,7 @@ esp_err_t ConfigManager::get_string(const char *key, std::string& out) const {
size_t required_size; // get size of the string size_t required_size; // get size of the string
if (ret = nvs_get_str(config_handle, key, nullptr, &required_size); ret != ESP_OK) { if (ret = nvs_get_str(config_handle, key, nullptr, &required_size); ret != ESP_OK) {
ESP_LOGE(TAG, "get_string failed to get string size"); ESP_LOGE(TAG, "get_string failed to get string size when reading %s", key);
return ret; return ret;
} }