Extract duplicate context query from controller
Merge pull request #161 from kytrinyx/contexts-stats

Extract duplicate context query from controller