factored out a 'return'
compressed an if..else