Revert "fix variable passing"

This reverts commit 2421449df61ccd153fcf2bf50c96606116106f21.
Revert "Fixed infinite loop"

This reverts commit fe5efef3e3e0f3dd83e3920e8329e2ef386dba69.