And rather check if(list.isEmpty()) than value != ...
# getting-started
a
And rather check if(list.isEmpty()) than value != null