JSHint gave warnings

JSHint failed, fixed up based on the warnings.