check for null as well. I still think you are over-engineering here. you could rather construct a collection of JobHistoryRecord and return it.