BBC Scotland has issued an unprecedented plea for online "restraint" after journalists covering the election were subjected intimidation, threats and abuse.

In a strongly-worded statement, head of programmes Donalda MacKinnon raised fears about the safety of some reporters following "unacceptable" online attacks.

A number of journalists investigating the leaked civil service memo which claimed Nicola Sturgeon wanted the Conservatives to remain in power were targeted with vicious abuse by so-called cybernats.

Ms MacKinnon said: "We welcome social media engagement with our audiences.

"But there are times when social media and other online sites have been used to abuse and threaten journalists.

"This is completely unacceptable and our journalists are entitled to carry out their work without the threat of unwarranted personal attacks online."

She added: "The safety of our staff is of paramount concern to us and we are doing everything in our power to ensure they can carry out their work helping to inform our audiences on this major story without intimidation or abuse."

According to the leaked memo, Ms Sturgeon told the French ambassador, Sylvie Bermann, she wanted David Cameron to remain in power after the election. The claim was categorically denied by the First Minister and dismissed by the ambassador.

Meanwhile, a former SNP activist who shared a platform with Alex Salmond and Nicola Sturgeon during the referendum campaign has confirmed that he has defected to Labour.

Muhammad Shoaib, the organiser of Asians for Independence, said he had switched sides after Nicola Sturgeon expressed support for the Greens in England and Plaid Cymru in Wales.

However, he said that he remains a supporter of Scottish Independence and would back a Yes vote should another referendum take place.

Earlier yesterday, after claims of Mr Shoaib's defection emerged, a spokesman for the SNP said that he had not been in touch to resign his membership that the party understood he would not be joining Labour.

The party claimed the episode was a "serious embarrassment" for Jim Murphy, before Labour confirmed that Mr Shoaib had indeed joined their ranks.

Mr Shoaib said: "It's in the best interests of the Scottish people to have a Labour government, otherwise we will face huge austerity."