fixing NPE when there is a single section in a visible area in the list