added doesAccept method