The following passage is quoted from the fifth chapter "Diagon Alley" of Harry Potter and the Philosopher's Stone. What does the word "them" in bold refer to? I think that grammatically speaking, it should refer to Harry and Doris, but contextually speaking, it should refer to Hagrid and Harry. Can the word "them", not the word "themselves", include the subject "Hagrid"?
But the others wouldn't let Professor Quirrell keep Harry to himself. It took almost ten minutes to get away from them all. At last, Hagrid managed to make himself heard over the babble. "Must get on -- lots ter buy. Come on, Harry." Doris Crockford shook Harry's hand one last time and Hagrid led them through the bar and out into a small, walled courtyard, where there was nothing but a dustbin and a few weeds.