If there were good evidence that taking anti-inflammatory medications were harmful to your immune response, then we … getting a vaccine, then I would feel comfortable with them taking a pain reliever before getting the vaccine.
Source: best pain reliever