The pronoun who is inflected this way: subject - who object - whom possessive - whose In your sentence, the case of the pronoun is determined by its position in the dependent clause. So you have picked the "correct" word, according to its function as direct object. However, this pronoun has been losing its inflection.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.