I have started to read a novel for practice. I came across these sentences. I can't make sense of the part 通って中に.
少年はあそこ一夜過ごすことに決めた。彼は羊の群れが、壊れかけた門を通って中に、入るのを見届けてから、夜中に羊が迷い出さないように、何本かの棒を門にわたした。
I cannot find an explanation for the use of the combination of the verb in te-form and chuu ni. Figuring out this part would help me a lot to put together what the sentence says.