“Seek what benefits you, and seek help ONLY from Allah and do not lose heart. If any adversity comes to you, do not say: ‘If only I had acted in such-and-such a way, it would have been such-and-such’ but instead, say:
‘Qadr Allahu wa Masha Fa’al’ (which means: Allah has decreed it and what He willed has happened)
For verily, the word “if” opens the way for the work of Satan.”
[Sahih Muslim]