Fix preloading on has_many :through association in combination with STI models.

This patch fixes #11078 by removing the type conditions from `through_scope`.
It is really inspired by #11082 and the comment from @neerajdotname.