Fix input validation hopefully. closes #7