Fixed bugs with MEC