Does function inherit variables from modifier?

by cotld   Last Updated November 06, 2018 02:28 AM

In a contract where a modifier like this would be reused a lot, is ID inherited by the function that uses the modifier? If not, this check would need to be in the function. If yes, is there any drawbacks from putting uint ID in the modifier?

modifier isMember (address _foo) {
  uint ID = memberIndex[_foo];
  require(ID != 0); 

Related Questions

Use same argument name in modifier and function

Updated November 06, 2018 01:28 AM

Modifier to only allow access via staticcall

Updated November 27, 2018 19:28 PM

Solidity modifiers: good or bad?

Updated February 22, 2019 22:28 PM