So long as your TJ is any model year but 98-99 it has the ability to generate and display its own DTCs (diagnostic trouble codes) so you don't need Autozone to do that for you. You haven't yet completed your Profile which shows your Jeep information so please complete it.
If you have any year but 98-99, you only need to turn the ignition switch on-off-on three times within five seconds and then keep it in the On position so it can run the diagnostics. Give it several seconds to work and then it will display any trouble codes it finds in the odometer. At a minimum, depending on your TJ's model year, it will at least say '55' or Done in the display, either of which by themselves indicate no trouble codes.
Error Code P1391 happens when the PCM (powertrain control module, also known as ECM or engine control module) has detected that the actual position of the CMP disagrees with its expected level as set by the manufacturer.
Have you checked the wiring harness that goes between the CMPS, CKPS and the ECM ?
There is a wiring harness that goes along the firewall behind the valve cover routed around a threaded head stud at the driver side rear corner of the head. The head stud threads are known to rub thru the split wire loom and wiring insulation interrupting the signals to and from the ECM.
There is a PDF of the Factory Service Manual that is downloadable in the TJ Resources section. Look in Section 8W for the wiring schematics; they will have harness connector numbers, wiring colors and pin outs to further assist in troubleshooting your problem.