quelea-projection / Quelea

Open source projection software for churches.
https://quelea.org
GNU General Public License v3.0
159 stars 145 forks source link

Replace object check with requireNonNullElseGet #461

Closed berry120 closed 3 years ago

berry120 commented 3 years ago

In SurvivorSongbookParser, lines 70-75, we're doing a manual null check, and then returning an empty list if null.

Instead, we should be using the Objects.requireNonNullElseGet() method to achieve the same thing in a single line.

Alpha-Knight-Zero commented 3 years ago

I have done this and sent a pull request.