Fixed getting cores from DB