On a 90 Pontiac lemans check engine light flashes on and off while driving down the road and engine cuts out at same time seems to be worse when you slow down can anyone help?

on the positive battery terminal there should be an orange wire attached, double check and make sure there isn't a short in that wire, i had the same trouble and it turned out to be that wire had a short in it, once i fixed it every thing was normal again