That's the exact same code as in ```equal_variables```. Can we refactor that?