Merge "Small fixes to StatsManager API." into pi-dev