I ran into the same issue. Kinda annoyed right now because after doing a convoluted nest along the lines of Weapon.where(zombie_id:Zombie.where(name:"Ash").id), which WAS accepted, I wanted to check the preferred answer to see if it was less convoluted, only to
(a) be dinged the 75 points for cheating, and
(b) discover that the "correct" answer involved a-priori knowledge of the zombies table where my original (if convoluted) answer didn't.
The most agreeable answer I can see is along the lines of @olivierlacan's, but it took a good 20 minutes of side-research to dig up a syntax which would get at the actual row returned by #where in a format which would accept #weapons. The ActiveRecord::Relation, at least on my end, wasn't even accepting .first or  without the checker preempting the evaluation with a big ugly (and usually unrelated hex-garbage) error, so I ended up needing to step through #to_a and, nonetheless, use #first instead of . Condensing the various experiments with intermediate variables down into 1 line, my solution was ultimately