fixed variable redefinition