President Donald Trump said on social media that the “powerful and deadly” strikes in the Nigerian state of Sokoto were carried out against IS gunmen.