I'm doing a code review and I've noticed that the developer has done this:
UserSession.LocationId = CheckInteger(elementValue);
with this wrapper
private int CheckInteger(string elementValue)
{
int outNumber;
int.TryParse(elementValue, out outNumber);
return outNumber;
}
I can't see that this brings very much to the party. Should I push back, or just let sleeping dogs lie? I don't think there's any particular company policy that covers this.