Fix qs not being removed when looking up endpoint