I work at a startup hiring senior software engineers. I have less than 1 year experience but I was asked to take technical interviews. I explained that they have wide skill set and I might not be the best person to interview them. They told me it's not a problem and that I can ask them questions related to what I already know.
So I interviewed a PayPal software engineer today and he has 6 years of experience. I've asked JS/TS specific questions like "here's a sample code, tell me what's wrong with it?" and I noticed that the candidate couldn't answer these questions. He started to get defensive and said that I shouldn't be asking these type of intricate questions given that it's easy to resolve the problematic code by relying on code editors' intelligence or simply googling the bug. In the end, we gave him a DSA question which he solved in 15 min.
I want to hear opinions of engineers here because I was expecting a senior engineer to know the "gotchas" of languages they have experience with and not just be good at DSA. I know it's important to have confidence in interviews, but is it okay to straight-up tell the interviewer to not ask language specific questions? Is asking language specific questions not the right way to evaluate someone's knowledge?