Bit of a strange one today

Was driving home as usual from work when in stop start traffic the idle all of a sudden became rough and my "Electronic Engine Cooling" light came on

Gave it a quick blip of the throttle and it cleared it

Engine wasnt going above 90c and its a totally standard car, the only known issue with it is that i know the manifold is cracked but i cant see why that would randomly throw the car off

I also have a sneaky feeling the AFM is degrading as every now and again on full throttle ill loose power for a second

Anyone had this issue?

Could the AFM caused the idle to screw up and in turn confuse the ECU to put the cooling light on?

Thanks in advance

P.S car is totally standard