esp-cpp / espp

C++ components for ESP
https://esp-cpp.github.io/espp/
MIT License
28 stars 9 forks source link

fix(nvs): pass ec reference to erase() #252

Closed guraj closed 1 month ago

guraj commented 1 month ago

Description

Fixed a bug by changing the ec parameter of erase() to pass the error code by reference, allowing it to correctly update the error state within the method.

Motivation and Context

Prior to this, changes made to the error code by erase() won't affect the original error code outside the method. This fix corrects the signature to reflect the ec convention of the other methods in the Nvs class.

Types of changes

github-actions[bot] commented 1 month ago

:white_check_mark:Static analysis result - no issues found! :white_check_mark: