Skip to content

Commit 9244a24

Browse files
committed
Remove unnecessary error log from CurrentFabricRemover
Currently, when the CurrentFabricRemover is successful it logs the following error with err log level: Remove Current Fabric Result : src/controller/CurrentFabricRemover.cpp:133: Success Get rid of the message if successful, it is confusing.
1 parent 1a8c6d2 commit 9244a24

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/controller/CurrentFabricRemover.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,8 @@ void CurrentFabricRemover::OnCommandFailure(void * context, CHIP_ERROR err)
145145

146146
void CurrentFabricRemover::FinishRemoveCurrentFabric(void * context, CHIP_ERROR err)
147147
{
148-
ChipLogError(Controller, "Remove Current Fabric Result : %" CHIP_ERROR_FORMAT, err.Format());
148+
if (err != CHIP_NO_ERROR)
149+
ChipLogError(Controller, "Remove Current Fabric Failed : %" CHIP_ERROR_FORMAT, err.Format());
149150
auto * self = static_cast<CurrentFabricRemover *>(context);
150151
self->mNextStep = Step::kAcceptRemoveFabricStart;
151152
if (self->mCurrentFabricRemoveCallback != nullptr)

0 commit comments

Comments
 (0)