diff --git a/slither/core/scope/scope.py b/slither/core/scope/scope.py index c6d18556e6..21f60517bf 100644 --- a/slither/core/scope/scope.py +++ b/slither/core/scope/scope.py @@ -95,7 +95,9 @@ def add_accesible_scopes(self) -> bool: def get_contract_from_name(self, name: Union[str, Constant]) -> Optional[Contract]: if isinstance(name, Constant): - return self.contracts.get(name.name, None) + name = name.name + if name in self.renaming: + name = self.renaming[name] return self.contracts.get(name, None) # region Built in definitions