refactoring isInclude method that filters stats
update stats store and publish only when a new stats is created