Praise for Trump for getting al-Baghdadi or for Obama getting Osama bin-Laden is pure window dressing. I don't think either (especially Trump if a hotel was not involved) could put a pin on a map of the Middle East as to where most of the countries are such as Kuwait, Yemen, UAE, etc. Even most members of the Cabinet really have no clue on the details.
Presidents rely on the information they receive from the heads of the respective agencies, CIA, NSA, Armed Forces, etc. When they think they have a high percentage opportunity to take out one of the main targets they inform the President.
The President says, "OK"
If successful, the President boasts and preens about how he directed the operation.
These intelligence operations take many years. In the al-Baghdadi case, it's being reported that he has been followed by US Intelligence since 2015. In the Osama bin Laden case, it also was many years, even pre-dating Obama back to the George W Bush years.
I personally never read too much into who is President at the time that Intelligence says they have positively identified a target and have a plan for his removal.
Rub a Dub