Clean some string comparisons
Make more use of String.IsNullOrWhiteSpace
Improve IndexOf operations