inventory: Fix static groups count on inventory backend
Refs #2285