fixed an error in variable declaration