varius fix for vars scope on new structure , need some more fix