Diarrhea while pregnant

Does anyone know any safe medication for diarrhea while pregnant?? I feel like it just gets worse if I keep not treating it