In most cases, this is caused by the ground, somehow remaining when the jack is removed from the trs jack.
First thing to check is if there are 3 contacts on the input jack, if there are only 2, then this is your issue.
if it is not, find the lug on the jack where the neg (-) side of the battery clips is, (if you have a multi-meter, this will be
very helpful) use a multi meter and switch it to "continuity", with the input jack not plugged in, test the neg (-) battery lug of the
jack with the other jack lugs (and cavity ground), if continuity is found, ensure that the ground is isolated from the neg (-) battery lug. Make sure that if there is cavity shielding, that it is not interfering with this. Also, ensure that there is no other ground used on the neg(-) lug of the input jack.