fixed wrong variable types