Removed white spaces from inputs when validating