fix bug with finding pData for secondary categories