fixed bug on variable creation