What function does ことをする serve here?


In ran into this sentence

> 「ベレト君は気に食わないこと全部に悪いことをしてました」

but I'm having a hard time making sense of it. I get that the first part means
that "the stuff Beret finds distasteful". But I'm not sure how to fit that in
the remaining which I'd reckon means "completely" and "did bad things".

It seems like there is a missing connective or two. Did the author make typo
here or is this usage a sense of ことをする I'm unaware?

Here's more context but I'm not if I'll help:

> 「噂ってありもしないことが大袈裟に広まったりするでしょ。多分それ」 （本当は違います。ベレト君は気に食わないこと全部に悪いことをしてました）




Grammatically nothing is missing in the sentence. It is

  * ペレト君は (Subject)
  * 気に食わないこと全部に (Indirect object)
  * 悪いことを (Object)
  * してました (Verb)

You may be mis-parsing 気に食わないこと全部に, which means _to all the things he doesn't
like_.

全... takes this pattern as in

  * ワールドカップを見た人全員 All the people who saw World Cup;
  * 今まで読んだ本全部 All the books I ever read.

Thus the sentence means _Pereto did bad things to all the things he found
distasteful_.

I suppose it means "he behaved badly (towards his servant?) each time he found
something distasteful" (as far as I browsed the beginning chapter). The
phrasing of the sentence is actually a little strange in the sense that it
does not really sound _he got nasty towards one particular person_.




Grammatically nothing is missing in the sentence. It is

  * ペレト君は (Subject)
  * 気に食わないこと全部に (Indirect object)
  * 悪いことを (Object)
  * してました (Verb)

You may be mis-parsing 気に食わないこと全部に, which means _to all the things he doesn't
like_.

全... takes this pattern as in

  * ワールドカップを見た人全員 All the people who saw World Cup;
  * 今まで読んだ本全部 All the books I ever read.

Thus the sentence means _Pereto did bad things to all the things he found
distasteful_.

I suppose it means "he behaved badly (towards his servant?) each time he found
something distasteful" (as far as I browsed the beginning chapter). The
phrasing of the sentence is actually a little strange in the sense that it
does not really sound _he got nasty towards one particular person_.

