stopped the var functions after error