ROME (Reuters) - Italian police have arrested an immigrant from Gambia suspected of planning an attack on behalf of the Islamic State (IS) militant group, a prosecutor said on Thursday.

Alagie Touray was arrested on April 20 as he was leaving a mosque in Licola, near the southern city of Naples, after local authorities received a tip off from Spanish intelligence.

Prosecutor Giovanni Melillo said investigators had found a video of Touray swearing allegiance to IS leader Abu Bakr al-Baghdadi. “This gesture is often followed by a terrorist attack,” Melillo told reporters.

Touray, 21, wrote on the Telegram messaging service that he was “on a mission” and asked others to pray for him, Melillo said. He told police that he had received a “request” from a fellow Gambian to drive a car into a crowd of people, but said he had no intention of doing so.

Touray arrived in Italy in March 2017 after being rescued in the Mediterranean from a boat packed with 638 other migrants. He was subsequently taken to a migrant center in Licola and had applied for political asylum. His request is still pending.

More than 600,000 immigrants have come to Italy over the past five years, most of them from sub-Saharan Africa. The influx has become a major political issue, helping to fuel support for the far-right League, which became the second largest party in the lower house of parliament following last month’s election.

“This is how this immigrant wanted to pay us back for asking for political asylum, poor fellow. Stop the invasion before it is too late,” League leader Matteo Salvini wrote on Twitter shortly after Touray’s arrest was announced.