index needed only for slave

This commit is contained in:
Emmanuel Garette 2022-03-12 07:58:51 +01:00
parent f33b4ebc2a
commit d736d09e42

View file

@ -341,7 +341,7 @@ async def manager_callback(callbk: Param,
return option.impl_getsuffix()
if isinstance(callbk, ParamSelfOption):
if leadership_must_have_index and option.impl_get_leadership() and index is None:
if leadership_must_have_index and option.impl_is_follower() and index is None:
raise Break()
value = await calc_self(callbk, option, index, orig_value, config_bag)
if not callbk.todict:
@ -382,7 +382,7 @@ async def manager_callback(callbk: Param,
callbk_option = callbk_option.to_dynoption(rootpath,
suffix,
subdyn)
if leadership_must_have_index and callbk_option.impl_get_leadership() and index is None:
if leadership_must_have_index and callbk_option.impl_is_follower() and index is None:
raise Break()
if config_bag is undefined:
return undefined