Code cleanup

Removed unneeded if construct. Just call .first which will be faster than a condition.