Not around the whole function, but before the if should work.