Hey, definitely check with your doctor before taking any medicine in pregnancy, even if they prescribed it. Different doctors have different approaches depending on what you're on, so it's best to confirm with yours that it's safe for your second trimester especially. In the meantime, rest well and stay hydrated, okay? Feel better soon.
Did you tell doctor that you’re pregnant? If yes, then it’s safe as doctor will prescribe you pregnancy safe medication. Do not self medicate.