Changed all String comparisons to use .equals instead of ==