Checking mFinishedCommandCount doesn't require mpPendingResponseTracker (#32375)
diff --git a/src/app/CommandSender.cpp b/src/app/CommandSender.cpp
index 268fd33..af317f7 100644
--- a/src/app/CommandSender.cpp
+++ b/src/app/CommandSender.cpp
@@ -497,10 +497,7 @@
bool canAddAnotherCommand = (mState == State::AddedCommand && mBatchCommandsEnabled && mUseExtendableCallback);
VerifyOrReturnError(mState == State::Idle || canAddAnotherCommand, CHIP_ERROR_INCORRECT_STATE);
- if (mpPendingResponseTracker != nullptr)
- {
- VerifyOrReturnError(mFinishedCommandCount < mRemoteMaxPathsPerInvoke, CHIP_ERROR_MAXIMUM_PATHS_PER_INVOKE_EXCEEDED);
- }
+ VerifyOrReturnError(mFinishedCommandCount < mRemoteMaxPathsPerInvoke, CHIP_ERROR_MAXIMUM_PATHS_PER_INVOKE_EXCEEDED);
if (mBatchCommandsEnabled)
{