diff --git a/core/constraints/arbitrum.py b/core/constraints/arbitrum.py index c9c1714..ea9c9f1 100644 --- a/core/constraints/arbitrum.py +++ b/core/constraints/arbitrum.py @@ -119,8 +119,8 @@ def is_observed(self, *args, **kwargs) -> bool: for user_address in self.user_addresses: try: address = token_client.to_checksum_address(user_address) - delegated_address = token_client.get_delegates_address() - if ( + delegated_address = token_client.get_delegates_address(user_address) + if not delegated_address or ( ConstraintParam.ADDRESS.name in self.param_keys() and delegated_address.lower() != self.param_values[ConstraintParam.ADDRESS.name].lower() diff --git a/core/constraints/optimism.py b/core/constraints/optimism.py index be182a0..7bf81fb 100644 --- a/core/constraints/optimism.py +++ b/core/constraints/optimism.py @@ -50,8 +50,8 @@ def is_observed(self, *args, **kwargs) -> bool: for user_address in self.user_addresses: try: address = token_client.to_checksum_address(user_address) - delegated_address = token_client.get_delegates_address() - if ( + delegated_address = token_client.get_delegates_address(user_address) + if not delegated_address or ( ConstraintParam.ADDRESS.name in self.param_keys() and delegated_address.lower() != self.param_values[ConstraintParam.ADDRESS.name].lower()