Revert "Improvement on variable handling"

This reverts commit 217eb4e9af3f90f23adb4360ed97391ba478ea64.