Ibuprofen while pregnant

Ive had a splitting migraine all morning to the point I couldn't even hold my eyes open, I tried everything from a warm bath and water and some caffeine and nothing helped, I ended up taking two ibuprofen at around 1200 this afternoon, then I realized you aren't supposed to take that while pregnant. I'm 5 weeks 1 day, everything should be fine, right?