Hey again ! Just saw your post of the 2001 cherokee. Well this '89 is a little different . If the engine is not stalling or losing power , a number of things can cause it. It's the old school Renix system which were fine when they ran , but more trouble than they were worth when they didn't , and that was often. Any computer on any engine can be the fault but not always the computer itself. The ground wires where the O2 sensor grounds for the computer should be where the battery ground is bolted to the block. I would start with cleaning these and all grounds you find such as the braided chassis ground at the rear of the cylinder head. Give the idle air control motor a cleaning to see if that helps too. Having the electrical system properly grounded and good conductive connections to all engine electrical is a good start for the engine to run right.
My dad had an '89 and we were on that jeep more than he was driving it . Always something.
Clean this , fix that . Replace this , now what wrong ? Man that jeep was great when it ran , but was a workout to keep it running right. Start with these suggestions and see how it runs after.
best of luck at it . Greg