Fix pages count