to fix: resourcesCount vs resourcesTotal.