Continued stalling

I have an 01 Mustang V6 which recently gave me some trouble where it would run fine for a while and then stall while driving. The original error code I got was P1518 which lead me to find that my IMCR was missing a plastic bushing that connected the metal rods to the engine. I replaced it and put the manifold back on and reconnected everything but the engine continues to stall after running for a few minutes from a cold start.
I connected my code reader and the codes I got back were P0122 and P1504. Any information on how to fix the problems associated with these codes without taking my car to an expensive repair shop would be appreciated.
I have checked to make sure my fuel pump and spark plugs are working correctly so they are not the problem as many people have suggested.

The Ford DTC P1504 points to a problem with the Idle Air Control circuit.

https://www.rockauto.com/en/catalog/ford,2001,mustang,3.8l+v6,1372632,fuel+&+air,idle+air+control+(iac)+valve,6072

Tester

Did you damage the wires to the IAC removing the intake? Or maybe they were already damaged or corroded? Check that.

The P0122 code indicates the following;

Faulty throttle position sensor.
Throttle position sensor harness is open or shorted
Throttle position sensor circuit poor electrical connection

Seems like a wiring problem to the throttle position sensor as well… right there with the IAC wiring. Coincidence? Probably not.