Is valtrex safe for pregnancy?

Has anyone taken valtrex while pregnant and it was okay? My OB nurse prescribed it to help my cold sore heal a little quicker so I'm guessing it's alright but everything says don't take if you're pregnant so I'm confused?