improved code in updateResCount
Merge branch 'projection-summary-graph' into deploy