Minor refactor: Move return false into if-statement