I have to deactivate the MDS when provisioning my sites. I have tried with an event receiver in a custom feature but it seems that when I execute this code in the receiver
Guid featureGuid = new Guid("87294C72-F260-42f3-A41B-981A2FFCE37A");
if (mySiteWeb.Features[featureGuid] != null)
{
mySiteWeb.Features.Remove(featureGuid);
}
nothing is happenning.
This only works once the my site is created and throughout the User Interface. If I go to Manage Site Features
and Deactivate and Activate my custom feature manually the MDS turns off.
Any idea how to achieve this?