[mle] allow setting router eligible attr to false for MTD (#4450)

This commit is contained in:
konradderda
2020-01-06 10:45:28 -08:00
committed by Jonathan Hui
parent aa9a45d212
commit 77ae260c77
+1 -1
View File
@@ -106,7 +106,7 @@ otError MleRouter::SetRouterEligible(bool aEligible)
{
otError error = OT_ERROR_NONE;
VerifyOrExit(IsFullThreadDevice(), error = OT_ERROR_NOT_CAPABLE);
VerifyOrExit(IsFullThreadDevice() || !aEligible, error = OT_ERROR_NOT_CAPABLE);
mRouterEligible = aEligible;